Skip to content

Commit

Permalink
Don't enable xdebug by default in ddev-webserver, fixes ddev#4597 (dd…
Browse files Browse the repository at this point in the history
  • Loading branch information
rfay authored Jan 29, 2023
1 parent accb23f commit 9400cb5
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions containers/ddev-webserver/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -90,11 +90,11 @@ RUN curl --fail -JL -s -o /usr/local/bin/mkcert "https://dl.filippo.io/mkcert/la
RUN mkdir -p /home/blackfire && chown blackfire:blackfire /home/blackfire && usermod -d /home/blackfire blackfire

ADD ddev-webserver-dev-base-files /
RUN phpdismod blackfire xhprof
RUN phpdismod blackfire xdebug xhprof

RUN set -x; curl --fail -sSL "https://github.com/drud/MailHog/releases/download/v${MAILHOG_VERSION}/MailHog_linux_${TARGETPLATFORM##linux/}" -o /usr/local/bin/mailhog && chmod +x /usr/local/bin/mailhog

RUN phpdismod xdebug && curl -sSL --fail --output /usr/local/bin/phive "https://phar.io/releases/phive.phar" && chmod 777 /usr/local/bin/phive && phpenmod xdebug
RUN curl -sSL --fail --output /usr/local/bin/phive "https://phar.io/releases/phive.phar" && chmod 777 /usr/local/bin/phive
RUN set -o pipefail && curl --fail -sSL https://github.com/pantheon-systems/terminus/releases/download/$(curl -L --fail --silent "https://api.github.com/repos/pantheon-systems/terminus/releases/latest" | perl -nle'print $& while m{"tag_name": "\K.*?(?=")}g')/terminus.phar --output /usr/local/bin/terminus && chmod 777 /usr/local/bin/terminus
RUN set -o pipefail && curl --fail -sSL https://github.com/platformsh/platformsh-cli/releases/download/$(curl -L --fail --silent "https://api.github.com/repositories/16695539/releases/latest" | perl -nle'print $& while m{"tag_name": "\K.*?(?=")}g')/platform.phar --output /usr/local/bin/platform && chmod 777 /usr/local/bin/platform

Expand Down
4 changes: 2 additions & 2 deletions containers/ddev-webserver/tests/ddev-webserver/general.bats
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@
fi
}

@test "verify that xdebug is enabled by default when the image is not run with start.sh" {
docker run --rm $DOCKER_IMAGE bash -c 'php --version | grep "with Xdebug"'
@test "verify that xdebug is not enabled by default" {
docker run --rm $DOCKER_IMAGE bash -c 'php --version | grep -v "with Xdebug"'
}

@test "verify apt keys are not expiring" {
Expand Down
2 changes: 1 addition & 1 deletion pkg/versionconstants/versionconstants.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ var SegmentKey = ""
var WebImg = "drud/ddev-webserver"

// WebTag defines the default web image tag
var WebTag = "20230106_container_start_hooks" // Note that this can be overridden by make
var WebTag = "20230128_xdebug_build_time" // Note that this can be overridden by make

// DBImg defines the default db image used for applications.
var DBImg = "drud/ddev-dbserver"
Expand Down

0 comments on commit 9400cb5

Please sign in to comment.