Repository navigation
Split secrets out of .env into .env.secrets - #56
Merged
Merged
Conversation
Same split as flyfun-weather and flyfun-apps: plain configuration stays in .env, secrets (DATABASE_URL, JWT_SECRET, GOOGLE_CLIENT_SECRET, APPLE_PRIVATE_KEY) move to .env.secrets, which the owner's config repo keeps sops-encrypted and syncfiles decrypts on the host (mode 600). - docker-compose: .env.secrets as an optional second env_file (only HOST_DATA_DIR is interpolated, so nothing is blanked by the split). - .gitignore / .dockerignore: .env.* ignored, samples re-included. The old `.env` entries did not match .env.secrets (public repo; image context). - scripts/asc.py, scripts/play.py: load .env.secrets after .env. - .env.sample split, new .env.secrets.sample. No code path changes: the app reads os.environ (compose in prod; the dev server sets ENVIRONMENT=development and loads no .env). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01W8cMQN8Qa8jZk17v72poeo
Code ReviewReviewed the 🤖 Generated with Claude Code |
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.
Same split as roznet/flyfun-weather#972 and roznet/flyfun-apps#41: plain config stays in
.env, and secrets (DATABASE_URL,JWT_SECRET,GOOGLE_CLIENT_SECRET,APPLE_PRIVATE_KEY) move to.env.secrets. The owner's config repo keeps that file sops-encrypted, and syncfiles decrypts it on the host (mode 600).No behaviour change until a host has a
.env.secrets.docker-compose.yml:.env.secretsis an optional secondenv_file. OnlyHOST_DATA_DIRis interpolated, so moving keys out of.envcan't blank anything (unlike flyfun-apps'environment:pass-throughs)..gitignore/.dockerignore:.env.*is now ignored and both samples are re-included. The old.enventries didn't cover.env.secrets, which matters for this public repo and for the image build context.scripts/asc.py,scripts/play.py: load.env.secretsafter.env. A missing file is a silent no-op in python-dotenv..env.samplesplit, plus a new.env.secrets.sample.The app needs no change: it reads
os.environ(from compose in prod; the dev server setsENVIRONMENT=developmentand loads no.env).Checks:
docker compose configpasses without a.env.secrets..env,.env.secretsand.env.triageare ignored; both samples are tracked.src/is untouched.🤖 Generated with Claude Code
https://claude.ai/code/session_01W8cMQN8Qa8jZk17v72poeo