AWS ☆☆ Road to deployment 2 (short version, 4 times in total)

1) Background </ font>

This is the second time. Build an instance of AWS to deploy your portfolio. Since there are so many procedure articles on how to set up an instance, here I will describe the procedure very briefly, including a memorandum. We will proceed with all 4 episodes.

2) Environment </ font>

item Contents
OS.Amazon Linux AMI release 2018.03
Ruby v2.5.1
Ruby On Rails v5.2.4.3
MySQL v5.6

3) Contents </ font>

** The following work will proceed on AWS. I think it takes about 45 minutes for all settings. (30 minutes if you know the setup) ** </ font>

(1) Use of yum package (5 minutes)

--Update yum package --Introduction of various packages (Because it is long, make a note of it.)

CMD>sudo yum -y install git make gcc-c++ patch libyaml-devel libffi-devel libicu-devel zlib-devel readline-devel libxml2-devel libxslt-devel ImageMagick ImageMagick-devel openssl-devel libcurl libcurl-devel curl

(2) Introduction of JS package (5 minutes)

--Introduction of node.js

(3) Ruby installation and configuration (15 minutes)

--Installing rbenv (* It takes time here) </ font> --.Bash_profile setting (Ruby path setting) and reloading --installing and rehashing ruby-build

(4) Mysql settings and DB connection (10 minutes)

--MySQL installation (V5.6) --Starting the service --DB administrator password setting and connection confirmation

(5) EC2 instance and GitHub ssl authentication settings (10 minutes)

It's a little difficult here. --Create a key pair. The following command.

ssh-keygen -t rsa -b 4096

--Access your Git and set the RSA key pair to allow SSL communication (just paste from ssh-rsa ... to the end) --Confirmation of communication from EC2 to git

[ec2-user@ip-172-31-xxxx .ssh]$ ssh -T [email protected]
(abridgement)
Hi Daisuke-Ichikawa-2! You've successfully authenticated, but GitHub does not provide shell access.

The above is a short description. Some commands take a considerable response time, so it's better to wait until the prompt comes back. Also, after setting up so far, you should restart the instance. After restarting, the Mysql service is not started and needs to be started.