Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add permission error when user cannot write to /etc/nginx folder #62

Merged
merged 6 commits into from
Jan 17, 2025

Conversation

poespas
Copy link
Collaborator

@poespas poespas commented Dec 30, 2024

Currently users get a very vague message when they run the nginx_config_reloader on an user that isn't able to write to /etc/nginx, this PR should solve this and add the check.

Before:

2024-12-30 06:25:19,553 nginx_config_reloader INFO     /data/web/nginx
2024-12-30 06:25:19,553 nginx_config_reloader DEBUG    Applying new config
2024-12-30 06:25:19,647 nginx_config_reloader ERROR    Installation of magento config failed

After:

2024-12-30 06:22:14,216 nginx_config_reloader INFO     /data/web/nginx
2024-12-30 06:22:14,216 nginx_config_reloader DEBUG    Applying new config
2024-12-30 06:22:14,229 nginx_config_reloader ERROR    No write permissions to main nginx config directory, please check your permissions.

Copy link
Contributor

@tdgroot tdgroot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, can you add a test to reflect the changes in _apply?

@poespas poespas merged commit 916e9e1 into ByteInternet:master Jan 17, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants