Install Nginx on Linux
http://nginx.org/en/linux_packages.html#mainline
For Debian/Ubuntu, in order to authenticate the nginx repository signature and to eliminate warnings about missing PGP key during installation of the nginx package, it is necessary to add the key used to sign the nginx packages and repository to the
codename
Ubuntu:
apt
program keyring. Please download this key from our web site, and add it to the apt
program keyring with the following command:For Ubuntu replace codename with Ubuntu distribution codename, and append the following to the end of thesudo apt-key add nginx_signing.key
/etc/apt/sources.list
file:codename
Ubuntu:
Version Codename Supported Platforms 14.04 trusty x86_64, i386, aarch64/arm64 16.04 xenial x86_64, i386, ppc64el, aarch64/arm64 17.10 artful x86_64, i386 18.04 bionic x86_64
deb http://nginx.org/packages/ubuntu/ codename nginx deb-src http://nginx.org/packages/ubuntu/ codename nginx
For Debian/Ubuntu then run the following commands:
apt-get update apt-get install nginx
Start nginx
$ sudo systemctl start nginxapt-get install nginx
or
$ sudo service nginx start
Restart nginx
$ sudo systemctl restart nginxapt-get install nginx
or
$ sudo service nginx restart
댓글
댓글 쓰기