fix: resolve v1.11.0 log location bugs in baremetal and docker setups#450
Open
TrezorHannes wants to merge 2 commits into
Open
fix: resolve v1.11.0 log location bugs in baremetal and docker setups#450TrezorHannes wants to merge 2 commits into
TrezorHannes wants to merge 2 commits into
Conversation
- Configure initialize.py to use absolute paths based on BASE_DIR for the RotatingFileHandler logging locations. - Update gui/views.py logs view to use settings.BASE_DIR to construct the absolute path to lndg-controller.log. - Add WorkingDirectory to systemd service template (systemd.sh/systemd.md) to fix CWD dependencies when starting from systemd (where default CWD is /). - Change StandardOutput/StandardError to journal in systemd service configuration to prevent root-permission issues and duplicate log writing. - Remove stdout/stderr file redirection from docker-compose.yaml and README.md to let the application-level RotatingFileHandler handle file logging cleanly without duplication or lock conflicts. Resolves cryptosharks131#449
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.
PR: Fix v1.11.0 log location bugs in baremetal and docker setups
Summary of Changes
Detailed Changes
BASE_DIRfor RotatingFileHandler logs (lndg-controller.logandlndg-web.log)./logsview logfile path absolutely usingsettings.BASE_DIR.WorkingDirectoryto systemd service template and redirected stdout/stderr to standardjournalinstead of/var/log/lndg-controller.log.> /app/data/lndg-controller.log 2>&1) to let Python's internal file rotating handler manage file logging cleanly.Resolves #449
Testing Strategy
manage.py check) which passes cleanly. Live tested under systemd on VPS, validating that log files are created under user permissions indata/and updated in real-time.