コンテンツにスキップ

Environment

item version
Server さくらのVPS
OS CentOS Stream release 9
item path
nginx config /etc/nginx/nginx.conf
public directory /usr/share/nginx/html

Install

  1. install Nginx
    $ sudo dnf -y install nginx
    
  2. change settings
    path: /etc/nginx/nginx.conf
  3. start Nginx
    $ sudo systemctl enable --now nginx
    

Command

su権限必要なものあり

command 内容
systemctl start nginx 起動
systemctl stop nginx 停止
systemctl restart nginx 再起動

Reference


最終更新日: August 14, 2023
作成日: August 14, 2023