LoginSignup
0
1

More than 5 years have passed since last update.

amazon linux でウェブサーバーを作る

Posted at

前提

awsのec2にamazon linuxでインスタンスが既に立ち上がっていてssh接続でコマンドからサーバーに入れていること。

実装

sudo yum update -y
sudo yum install -y httpd24 php70 mysql56-server php70-mysqlnd
sudo service httpd start
sudo chkconfig httpd on
chkconfig --list httpd

80番ポートを解放する

下記のurlからコンソールにアクセスして画面左のセキュリティグループを選択して、ポートを解放する。

Screen Shot 2018-03-07 at 9.24.43.png

Screen Shot 2018-03-07 at 9.24.59.png

htmlファイルを作る

$ pwd
/var/www/html

$ ls
index.html

実行

Screen Shot 2018-03-07 at 9.27.32.png

参考

Tutorial: Install a LAMP Web Server with the Amazon Linux AMI

0
1
0

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
0
1