feat: switch to systemctl for interacting with the nginx init process

This commit is contained in:
Jose Diaz-Gonzalez committed 2022-11-29 01:38:36 -05:00
1 parent 5fed0c45ac
commit a8bc8044e4
3 files changed
+5

No files matched your search

+2
View File
@@ -132,6 +132,8 @@ fn-nginx-vhosts-nginx-init-cmd() {
# support docker-based installations
if [[ -x /usr/bin/sv ]]; then
sudo /usr/bin/sv "$CMD" "$NGINX_INIT_NAME"
elif [[ -x /usr/bin/systemctl ]]; then
sudo /usr/bin/systemctl "$CMD" "$NGINX_INIT_NAME"
else
sudo "/etc/init.d/$NGINX_INIT_NAME" "$CMD"
fi