LoginSignup
10

More than 5 years have passed since last update.

CentOS 7 nginx + php-fpm のインストール

Last updated at Posted at 2014-10-20

CentOS に nginx と php-fpm をインストールする手順。
yum を使って簡単にインストール。

インストール

$ sudo yum install epel-release
$ sudo yum install nginx
$ sudo yum install php-fpm

nginxの起動

$ sudo systemctl start nginx

デフォルトは80番ポートで起動

nginxのconf は下記のディレクトリ以下にあるので適宜編集する。

/etc/nginx/

php-fpmの起動

$ systemctl start php-fpm

デフォルトは9000番ポートで起動する

php-fpmのconfにあるので適宜編集する。

/etc/php-fpm.conf
/etc/php-fpm.d/

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
10