Creating VPC and using bastion host for private subnet using terraform

Bastion Host is Wordpress Instance

What is Terraform ?

What is VPC ?

Provider with Iam username “akhil”
Key pair -> “key1.pem”
VPC -> “vpc-task”
Public and Private Subnets
Elastic IP
NAT Gateway
Internet Gateway
Route Table 1
Route Table for associating NAT Gateway
Wordpress Security Groups
Wordpress Instance
Mysql Security Groups
Mysql Instance
Output of “terraform init”
Private Subnet
Public Subnet
Key Pair
Internet Gateway
NAT Gateway
Routing Table for Internet Gateway
Routing Table for NAT Gateway(Private Subnet)
Mysql Instance
Wordpress Instance
SSH is not possible from CMD
SSH is not possible not even through Browser
SSH for Wordpress Instance is possible
WinSCP — login using Public IP of Wordpress Instance and then give user as bitnami and in authentication provide your key in ppk format (It will automatically convert .pem to .ppk)
SSH is possible now using Wordpress Instance — Now we are able to access our mysql instance.
I installed elinks package to mysql Instance
Elinks is installed and hence Internet Connectivity is there.
Wordpress Blog

I am a student and persuing under graduation in computer science and engineering.