Search code examples
ubuntunginxupstart

Cannot find upstart init script for Nginx


I installed Nginx. I can start, stop, etc... the service and the server are working on boot.

But, i cant seem to find the upstart init script for Nginx, not in /etc/init/ or anywhere in the system.

I read on the Nginx docs the following:

If you install NGINX from a repository, then it is likely that you already have an init script installed. If you installed from source, then you’ll want to find a script from below to help you out.

They dont say where the init file is located in the case you installed Nginx using aptitude.

Can anyone tell me please?

UPDATE:

Linux version ubuntu 14.04


Solution

  • When installing nginx, you may see two extra packages installed:

    sudo apt-get install nginx
    ...
    The following NEW packages will be installed:
    nginx nginx-common nginx-core
    ...
    

    You may see all files installed by package:

    dpkg -L nginx-common
    ...
    /etc/init.d/nginx
    ...
    

    It installs System V style init script, not upstart job.