We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5b5bc1f commit ef9524aCopy full SHA for ef9524a
scripts/packages/postinstall.sh
@@ -24,7 +24,7 @@ WORKER_USER=""
24
AGENT_GROUP="nginx-agent"
25
26
detect_nginx_users() {
27
- if command -V systemctl >/dev/null 2>&1 && [ "$(cat /proc/1/comm)" = "systemd" ]; then
+ if command -V systemctl >/dev/null 2>&1 && systemctl status nginx >/dev/null 2>&1 && [ "$(cat /proc/1/comm)" = "systemd" ]; then
28
printf "PostInstall: Reading NGINX systemctl unit file for user information\n"
29
nginx_unit_file=$(systemctl status nginx | grep -Po "\(\K\/.*service")
30
pid_file=$(grep -Po "PIDFile=\K.*$" "${nginx_unit_file}")
0 commit comments