Welcome! Log In Create A New Profile

Advanced

Re: .service ExecStartPre in example

Lucas Rolff
January 11, 2019 05:24AM
There's nothing wrong with testing the configuration before starting the web server.

The config is tested during restart, by the ExecStartPre. If you modify a config and you want to restart, you should execute nginx -t prior to restarting your service - but generally you'd want to use nginx -s reload as much as possible.

On 11/01/2019, 11.12, "nginx on behalf of Olaf van der Spek" <nginx-bounces@nginx.org on behalf of nginx-forum@forum.nginx.org> wrote:

What's the purpose of testing the configuration file in the systemd
example?
Just starting the server seems simpler.. and the test isn't run prior to a
restart request.


ExecStartPre=/usr/sbin/nginx -t

https://www.nginx.com/resources/wiki/start/topics/examples/systemd/

Posted at Nginx Forum: https://forum.nginx.org/read.php?2,282654,282654#msg-282654

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx


_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

.service ExecStartPre in example

Olaf van der Spek January 11, 2019 05:12AM

Re: .service ExecStartPre in example

Lucas Rolff January 11, 2019 05:24AM

Re: .service ExecStartPre in example

Olaf van der Spek January 11, 2019 05:28AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 322
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready