Panic: Handle numeric 3rd party service use of HTTP_EXPOSE or HTTPS_EXPOSE, fixes #2266 #2252
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The Problem/Issue/Bug:
It is possible to use a numeric value for HTTP_EXPOSE or HTTPS_EXPOSE environment variables in a 3rd-party service.
The code assumes that it will be a string, and crashes with
This was reported in TYPO3 slack by Elias Häußler, thanks!, https://typo3.slack.com/archives/C8TRNQ601/p1589356915138500
The docker-compose.selenium.yaml that caused this problem is posted at https://gist.github.com/eliashaeussler/df4d277a6c390094436ce2e34783fc3f
How this PR Solves The Problem:
Make sure the environment variable value is a string before using it.
Manual Testing Instructions:
ddev start
ddev describe
should work correctlyddev list
should behave correctlyWorkaround for affected users
Just change the affected HTTP_EXPOSE line to
for example, instead of
- HTTP_EXPOSE: 4444
Automated Testing Overview:
Related Issue Link(s):
Release/Deployment notes: