save
This commit is contained in:
parent
6ad86cf1d4
commit
5737f5ee50
4 changed files with 52 additions and 7 deletions
23
recipes/nginx/nginx.service.erb
Normal file
23
recipes/nginx/nginx.service.erb
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
sudo tee /etc/systemd/system/nginx-custom.service >/dev/null <<'EOF'
|
||||
[Unit]
|
||||
Description=nginx (custom prefix)
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=forking
|
||||
PIDFile=/pkg/nginx/run/nginx.pid
|
||||
ExecStart=/pkg/nginx/sbin/nginx
|
||||
ExecReload=/pkg/nginx/sbin/nginx -s reload
|
||||
ExecStop=/pkg/nginx/sbin/nginx -s quit
|
||||
TimeoutStopSec=5
|
||||
#User=nginx
|
||||
#Group=nginx
|
||||
LimitNOFILE=65535
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
|
||||
# sudo systemctl daemon-reload
|
||||
# sudo systemctl enable --now nginx-custom
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue