nginx custom script location
tomek at pipebreaker.pl
Wed May 16 19:09:32 UTC 2012
On Wed, May 16, 2012 at 06:10:08PM +0100, Jamie Nguyen wrote:
> On 16 May 2012 08:16, Tomasz Torcz <tomek at pipebreaker.pl> wrote:
> > On Wed, May 16, 2012 at 01:19:20AM +0200, Michal Schmidt wrote:
> >> On 05/16/2012 12:21 AM, Jamie Nguyen wrote:
> >> > /etc/init.d/nginx upgrade
> >> >
> >> >This has disappeared following migration to systemd, so my intention
> >> >is to include an nginx-upgrade shell script to replace this
> >> >functionality.
> >> >
> >> >My question is, where should this shell script go? In /usr/bin/nginx-upgrade?
> >> Yes, this looks like a good choice to me.
> >> Then immediately a question comes to mind: Shouldn't the script be
> >> pushed upstream, rather than being a Fedora-specific addition?
> > Also, implementing socket-activation in nginx would make it upgradable
> > without losing any connections.
> Sorry, could you clarify? I don't see how that would help in this situation.
> AFAIK, systemd socket activation is useful either for parallelization
> during system startup, or on-demand activation. The former doesn't
> help, and the latter is definitely not what we want for a web server.
If the new request comes during nginx restart¹, it won't be lost.
Socket is always opened by systemd and the connection will be buffered
until new nginx is ready to server it.
¹ in time between old nginx closing its socket and new nginx creating new
Tomasz Torcz "God, root, what's the difference?"
xmpp: zdzichubg at chrome.pl "God is more forgiving."
More information about the devel