diff options
| author | hc <hc@email.ch> | 2024-11-20 12:51:33 +0800 |
|---|---|---|
| committer | hc <hc@email.ch> | 2024-11-20 12:51:33 +0800 |
| commit | 853b82126baa1e8e408a10f91053c52626ffad29 (patch) | |
| tree | 2fc1de9695810681ba654aab3c2a4867aacc1ac7 /config_files/nginx.service | |
| parent | b1f88b682624e85b4b743343dfaaeed113b69413 (diff) | |
working
Diffstat (limited to 'config_files/nginx.service')
| -rw-r--r-- | config_files/nginx.service | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/config_files/nginx.service b/config_files/nginx.service new file mode 100644 index 0000000..7b5a697 --- /dev/null +++ b/config_files/nginx.service | |||
| @@ -0,0 +1,23 @@ | |||
| 1 | [Unit] | ||
| 2 | Description=The nginx HTTP and reverse proxy server | ||
| 3 | After=network-online.target remote-fs.target nss-lookup.target | ||
| 4 | Wants=network-online.target | ||
| 5 | |||
| 6 | [Service] | ||
| 7 | Type=forking | ||
| 8 | PIDFile=/run/nginx.pid | ||
| 9 | # Nginx will fail to start if /run/nginx.pid already exists but has the wrong | ||
| 10 | # SELinux context. This might happen when running `nginx -t` from the cmdline. | ||
| 11 | # https://bugzilla.redhat.com/show_bug.cgi?id=1268621 | ||
| 12 | ExecStartPre=/usr/bin/rm -f /run/nginx.pid | ||
| 13 | ExecStartPre=/usr/sbin/nginx -t | ||
| 14 | ExecStart=/usr/sbin/nginx | ||
| 15 | ExecReload=/usr/sbin/nginx -s reload | ||
| 16 | KillSignal=SIGQUIT | ||
| 17 | TimeoutStopSec=5 | ||
| 18 | KillMode=mixed | ||
| 19 | PrivateTmp=true | ||
| 20 | Environment="OPENSSL_CONF=/etc/pki/tls/openssl.pkcs11.cnf" | ||
| 21 | |||
| 22 | [Install] | ||
| 23 | WantedBy=multi-user.target | ||
