0
0

More than 3 years have passed since last update.

aws の練習

Last updated at Posted at 2020-08-03

AWSでサーバーを立ち上げ、Apache をインストールするまで。もしくはmysqlの設定まで。udemy の aws 講座の内容です。

VPC(Virtual Private Could)の作成

ログインしてVPC dashboardへ。
Create VPC
Name tag に名前。
IPv4 CIDR に10.0.0.0/16

Subntets から Create subnet
Name tag を入力
VPCを選択
Availability Zone を選択
IPv4 CIDR block に 10.0.10.0/24

Routingの設定

create internet gateway

Action からVPCにアタッチ。
vpc を選択
ルートテーブルの作成
name を入れて
vpc を選ぶ。
subnet 関連付け
ルートの編集
ルートの追加
0.0.0.0/0 をinternet gatewayにしてください。

create ec2 instance

AMIの選択。ex. Amazon Linux
Instance Type の選択 General purpose t2.micro(無料なので)
Step 3 Coufigure Instance Details
Network 作ったやつ
Subnet 作ったやつ
Auto assign Public IP Enable

Capacity Reservation None

next

Step4 Add Strage 8g next
Step5 Add Tags
key Name value start-aws-web

Step6 Configure Security Group
check Create a new security group
name yamaki-sg
description yamaki-sg
next

Launch
Key pair file を作って保存

Security Group設定

http通信の設定
インバウンド edit add rule
type http
Source 0.0.0.0/0, ::/0

ssh でインスタンスに接続

terminal 起動
インスタンスからIPv4 Public IP確認
ダウンロードしたキーペアをchmod 600
ssh -i key-pair ec2-user@domain

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