Repository navigation
Add .env.example for the host port overrides - #22
Merged
Merged
Conversation
Every other compose-based repo here ships one; this was the only one where the three port variables existed but had no file listing them, so the README table was the only place to find them. The compose file lives in deploy/, so compose looks for deploy/.env and would never read one at the root -- and the Makefile's exports would win over it in any case. The Makefile now reads .env itself, resolving each port as environment, then .env, then the default, so an inline POSTGRES_HOST_PORT=5433 still beats a value sitting in the file. .env is gitignored, matching the other repos that ship an example. Verified by copying the example to .env, setting 55433 and running make db with no inline variable: Postgres published on 55433 and the DB-backed suites passed against it.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
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.
The gap
Every other compose-based repo here ships a
.env.example. This was the only one where the three port variables existed but no file listed them, so the README table was the only place to find them. I hit this myself:make dbfailed on a taken 5432 and the variable name had to be dug out.Why it needed more than a new file
The compose file lives in
deploy/, so compose looks fordeploy/.envand would never read one at the repo root. Worse, the Makefile exports the port defaults, and a shell variable beats compose's.env— so a file dropped indeploy/would have been silently ignored whenever anything ran throughmake. A.env.exampleon its own would have been decorative.The Makefile now reads
.envitself and resolves each port as environment, then.env, then the default:.envsets 5433.envsets 5433, inline says 5599All three verified with
make -p..envis now gitignored, matching the four sibling repos that ship an example.End-to-end check
Copied the example to
.env, setPOSTGRES_HOST_PORT=55433, ranmake dbwith no inline variable:The DB-backed suites then passed against that port, confirming the connection strings follow the override too.