mirror of
https://github.com/YunoHost/package_linter.git
synced 2024-09-03 20:06:12 +02:00
Complain about attempts to restart nginx
This commit is contained in:
parent
2e976bcdf3
commit
171617cb8a
1 changed files with 2 additions and 0 deletions
|
@ -397,6 +397,8 @@ def check_deprecated_practices(script):
|
||||||
if "dd if=/dev/urandom" in script["raw"] or "openssl rand" in script["raw"]:
|
if "dd if=/dev/urandom" in script["raw"] or "openssl rand" in script["raw"]:
|
||||||
print_warning("Instead of 'dd if=/dev/urandom' or 'openssl rand', you might want to use ynh_string_random")
|
print_warning("Instead of 'dd if=/dev/urandom' or 'openssl rand', you might want to use ynh_string_random")
|
||||||
|
|
||||||
|
if "systemctl restart nginx" in script["raw"] or "service nginx restart" in script["raw"]:
|
||||||
|
print_wrong("Restarting nginx is quite dangerous (especially for web installs) and should be avoided at all cost. Use 'reload' instead.")
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
if len(sys.argv) != 2:
|
if len(sys.argv) != 2:
|
||||||
|
|
Loading…
Reference in a new issue