forked from letsencrypt/boulder
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Deconflict netaccess and boulder containers. (letsencrypt#3785)
Since these two containers were using the same entrpoint.sh, they were competing to run migrations and bind ports when run with `docker-compose up`. Since we don't need the netaccess container when doing `docker-compose up`, give it a separate entrypoint that exits immediately by default, but does the normal migrations when run with `docker-compose run`.
- Loading branch information
Showing
2 changed files
with
14 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
# For the boulder container, we want to run entrypoint.sh and start.py by | ||
# default (when no command is passed on a "docker-compose run" command line). | ||
# However, we want the netaccess container to run nothing by default. | ||
# Otherwise it would race with boulder container's entrypoint.sh to run | ||
# migrations, and one or the other would fail randomly. Also, it would compete | ||
# with the boulder container for ports. This is a variant of entrypoint.sh that | ||
# exits if it is not given an argument. | ||
if [[ "$@" = "" ]]; then | ||
echo "Not needed as part of 'docker-compse up'. Exiting normally." | ||
exit 0 | ||
fi | ||
$(dirname "${BASH_SOURCE[0]}")/entrypoint.sh "$@" |