refactor(deploy): simplify runtime configuration#355
Open
seebeen wants to merge 1 commit intoidank:masterfrom
Open
refactor(deploy): simplify runtime configuration#355seebeen wants to merge 1 commit intoidank:masterfrom
seebeen wants to merge 1 commit intoidank:masterfrom
Conversation
Owner
|
Hi @seebeen , thanks for the PR!
|
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.
This PR refactors the deployment/runtime setup for explainshell and simplifies how the web app is configured in local and container
environments.
The Dockerfile and Docker entrypoint were written by me.
The Python-side runtime/config/logging changes were implemented with assistance from OpenAI Codex. 5.4 high effort.
What Changed
DB_CACHE_BUSTstart.shtodocker/docker-entrypoint.sh8080to5000wgettocurlINFOby default viaLOG_LEVELcreate_app()resolve runtime config from env vars directly instead of shell-rendered Python argumentsrunserver.pyto bind to127.0.0.1by default for local developmentGoals
Primary:
Secondary:
Runtime / Env Changes
New or clarified runtime behavior:
PORTdefaults to5000runserver.pybinds to127.0.0.1by defaultHOST_IPcan still override the bind addressLOG_LEVELcontrolsexplainshell.*app logs and defaults toINFOGUNICORN_ACCESS_LOGenables Gunicorn access logs when set to1ortrueGUNICORN_ACCESS_LOG_FILEandGUNICORN_ACCESS_LOG_FORMATare available when access logging is enabledDB_PATHis resolved inside the app factory/runtime instead of being passed via shell-rendered Python argsIf a Docker Hub account is created and linked for this project, I can add a multi-arch container publishing workflow as a follow-up.
Looking forward to your feedback.