Nginx: Instalasi

From OnnoWiki
Revision as of 09:42, 14 June 2020 by Onnowpurbo (talk | contribs)
Jump to navigation Jump to search

Instalasi Nginx saja

sudo su
apt update
apt -y install nginx

Instalasi lengkap dengan mysql dan PHP, kira2 seperti di bawah ini,

sudo su
apt update
apt -y install nginx php5 php5-xmlrpc php5-mysql php5-gd php5-cli php5-curl \
mysql-client mysql-server

Cek / Test

Restart nginx

/etc/init.d/nginx restart

akses melalui web

http://ip-address
http://localhost

akan keluar kata-kata

Welcome to nginx!


Konfigurasi Default

Folder HTML default

root /usr/share/nginx/html;

Konfigurasi nginx

/etc/nginx/sites-enabled/default
chmod -Rf 755 /usr/share/nginx
chown -Rf nobody.nogroup /usr/share/nginx


Pranala Menarik