Repository navigation
Sync with docker-starter - #102
Merged
Merged
Conversation
* Serve the local production stack on port 8000 instead of 8080, which collides with the Traefik admin port of the dev stack * Let docker_exit_code() use the context's run service (php in the prod context) instead of a hardcoded builder * Do not dump the autoloader in the first composer install of the production build, it is dumped after the sources are copied * Expose the php-fpm status page (denied by nginx by default) * Pin the actions of the build-push workflow by SHA and compute the image tags in bash * Test the production images in the CI * Align .home/.gitignore, .gitignore and .dockerignore
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Brings the infrastructure in line with the final version of docker-starter's production images (jolicode/docker-starter#442), which this project prototyped.
Changes
castor start -c prod) served on port 8000 instead of 8080, which collides with the Traefik admin port of the dev stack (README updated)docker_exit_code()uses the context's run service (phpin theprodcontext) instead of a hardcodedbuildercomposer install(dependencies layer) no longer dumps the autoloader, it is dumped once the sources are copiedpm.status_path), denied by nginx by default, as in the starterdocker-compose.prod.yml: image and cache references use${REGISTRY}like the starter (castor always sets it, image names are unchanged:ghcr.io/jolicode/monologue/{php,nginx})build-push.yml: actions pinned by SHA, image tags computed in bashprod-imagesjob, which starts the production stack and checks the home page (behind HTTP Basic auth), a 404 on/index.phpand that the php image runs as uid 1000.home/.gitignore,.gitignoreand.dockerignorealigned with the starterIntentional differences with the starter
application/), no Node/yarn, unconditional production build stepscastor.php, overridable withREGISTRYin theprodcontext (same variable as the starter since Rename DS_REGISTRY to REGISTRY, and small fixes found while syncing projects docker-starter#445), as documented in the READMEValidation
Locally:
castor docker:build,castor --context=prod docker:build,castor app:install,qa:cs --dry-run,qa:twig-cs --dry-run,qa:phpstan,qa:security-auditand--context=test qa:phpunitall pass.Not run locally: the production stack (
castor start -c prod), so the newprod-imagesCI job has only been reviewed, not executed; thebuild-push.ymlworkflow only runs onmainand tags.