AWS : VPC (Virtual Private Cloud) 2 - VPC Wizard
Let's create a VPC using the VPC Wizard in the VPC Console.
Select VPC with a Single Public Subnet:
Click Select.
The configuration page below displays the CIDR ranges that we'll use for our VPC and subnet (10.0.0.0/16 and 10.0.0.0/24, respectively), and the hardware tenancy setting. Enter a name for VPC - this helps us identify it in the VPC console after we've created it.
We can leave the rest of the default settings and then click Create VPC to create our VPC, Internet gateway, subnet, and route table.
When the work completes, a status window confirms that our VPC has been successfully created. Click OK to close the status window and return to the VPC dashboard.
We can use the default settings for the components that the VPC Wizard creates for us.
This section describes how we can view these components and their settings using a VPC console.
In the VPC navigation pane, click Your VPCs.
The console displays our default VPC (I deleted it) and the VPC that we just created.
Select the VPC that we just created (Default VPC is No since the VPC that we created is a nondefault VPC, therefore the Default VPC column displays No).
To see Internet Gateways, in the navigation pane, choose "Internet Gateways". We can find the Internet gateway that's attached to our VPC by looking at the VPC column, which displays the ID and the name (if applicable) of the VPC.
Each VPC has a set of DHCP options, a main route table, and default network ACL.
The VPC that we just created has two route tables:
- The VPC came with a main route table by default
- and the VPC Wizard created a custom route table in addition.
Our subnet is associated with the custom route table, which means that we use the routes in that table to determine how the traffic for the subnet flows. If we add a new subnet to our VPC, it uses the main route table by default.
custom route table:
The first row in the table is the local route, which enables instances within the VPC to communicate. This route is present in every route table by default, and we can't remove it.
The second row shows the route that the VPC wizard added to enable traffic destined for an IP address outside the VPC (0.0.0.0/0) to flow from the subnet to the Internet gateway. We refer to this subnet as a public subnet because all traffic from the subnet goes to the Internet gateway.
main route table:
The main route table has a local route, but no other routes. Therefore, any subnet we create is not exposed to the Internet initially, it's a private subnet. To expose a new subnet as a public subnet, we can either change the routing in the main route table, or associate the subnet with a custom route table.
Here is the VPC we created:
- Created a VPC with a /16 CIDR block (a network with 65,536 private IP addresses).
- Attached an Internet gateway to the VPC.
- Created a size /24 subnet (a range of 256 private IP addresses) in the VPC.
- Created a custom route table, and associates it with our subnet so that traffic can flow between the subnet and the Internet gateway.
Our VPC comes with a default security group.
Any instance not associated with another security group during launch is associated with the default security group. In this guide, we'll create a new security group, "WebServerSG", and specify this security group when we launch an instance into our VPC.
A security group acts as a virtual firewall to control the traffic for its associated instances. To use a security group, we add the inbound rules to control incoming traffic to the instance, and outbound rules to control the outgoing traffic from your instance. To associate a security group with an instance, we specify the security group when we launch the instance. If we add and remove rules from the security group, those changes will be applied to the instances associated with the security group automatically.
In the navigation pane, choose Security Groups, and then choose Create Security Group. In the Group name field, enter "WebServerSG" as the name of the security group, and provide a description.
On the Inbound Rules tab, we may choose Edit and add rules for inbound traffic, and then Save when we're done.
When we launch an EC2 instance into a VPC, we must specify the subnet in which to launch the instance. In this case, we'll launch an instance into the public subnet of the VPC we created. We'll use the Amazon EC2 launch wizard in the Amazon EC2 console to launch our instance.
Now, we have this:
In the previous step, we launched our instance into a public subnet - a subnet that has a route to an Internet gateway. However, the instance in our subnet also needs a public IP address to be able to communicate with the Internet. By default, an instance in a nondefault VPC is not assigned a public IP address.
For this, please check Step 4: Assign an Elastic IP Address to Your Instance.
AWS (Amazon Web Services)
- AWS : EKS (Elastic Container Service for Kubernetes)
- AWS : Creating a snapshot (cloning an image)
- AWS : Attaching Amazon EBS volume to an instance
- AWS : Adding swap space to an attached volume via mkswap and swapon
- AWS : Creating an EC2 instance and attaching Amazon EBS volume to the instance using Python boto module with User data
- AWS : Creating an instance to a new region by copying an AMI
- AWS : S3 (Simple Storage Service) 1
- AWS : S3 (Simple Storage Service) 2 - Creating and Deleting a Bucket
- AWS : S3 (Simple Storage Service) 3 - Bucket Versioning
- AWS : S3 (Simple Storage Service) 4 - Uploading a large file
- AWS : S3 (Simple Storage Service) 5 - Uploading folders/files recursively
- AWS : S3 (Simple Storage Service) 6 - Bucket Policy for File/Folder View/Download
- AWS : S3 (Simple Storage Service) 7 - How to Copy or Move Objects from one region to another
- AWS : S3 (Simple Storage Service) 8 - Archiving S3 Data to Glacier
- AWS : Creating a CloudFront distribution with an Amazon S3 origin
- AWS : Creating VPC with CloudFormation
- AWS : WAF (Web Application Firewall) with preconfigured CloudFormation template and Web ACL for CloudFront distribution
- AWS : CloudWatch & Logs with Lambda Function / S3
- AWS : Lambda Serverless Computing with EC2, CloudWatch Alarm, SNS
- AWS : Lambda and SNS - cross account
- AWS : CLI (Command Line Interface)
- AWS : CLI (ECS with ALB & autoscaling)
- AWS : ECS with cloudformation and json task definition
- AWS Application Load Balancer (ALB) and ECS with Flask app
- AWS : Load Balancing with HAProxy (High Availability Proxy)
- AWS : VirtualBox on EC2
- AWS : NTP setup on EC2
- AWS: jq with AWS
- AWS & OpenSSL : Creating / Installing a Server SSL Certificate
- AWS : OpenVPN Access Server 2 Install
- AWS : VPC (Virtual Private Cloud) 1 - netmask, subnets, default gateway, and CIDR
- AWS : VPC (Virtual Private Cloud) 2 - VPC Wizard
- AWS : VPC (Virtual Private Cloud) 3 - VPC Wizard with NAT
- DevOps / Sys Admin Q & A (VI) - AWS VPC setup (public/private subnets with NAT)
- AWS - OpenVPN Protocols : PPTP, L2TP/IPsec, and OpenVPN
- AWS : Autoscaling group (ASG)
- AWS : Setting up Autoscaling Alarms and Notifications via CLI and Cloudformation
- AWS : Adding a SSH User Account on Linux Instance
- AWS : Windows Servers - Remote Desktop Connections using RDP
- AWS : Scheduled stopping and starting an instance - python & cron
- AWS : Detecting stopped instance and sending an alert email using Mandrill smtp
- AWS : Elastic Beanstalk with NodeJS
- AWS : Elastic Beanstalk Inplace/Rolling Blue/Green Deploy
- AWS : Identity and Access Management (IAM) Roles for Amazon EC2
- AWS : Identity and Access Management (IAM) Policies, sts AssumeRole, and delegate access across AWS accounts
- AWS : Identity and Access Management (IAM) sts assume role via aws cli2
- AWS : Creating IAM Roles and associating them with EC2 Instances in CloudFormation
- AWS Identity and Access Management (IAM) Roles, SSO(Single Sign On), SAML(Security Assertion Markup Language), IdP(identity provider), STS(Security Token Service), and ADFS(Active Directory Federation Services)
- AWS : Amazon Route 53
- AWS : Amazon Route 53 - DNS (Domain Name Server) setup
- AWS : Amazon Route 53 - subdomain setup and virtual host on Nginx
- AWS Amazon Route 53 : Private Hosted Zone
- AWS : SNS (Simple Notification Service) example with ELB and CloudWatch
- AWS : Lambda with AWS CloudTrail
- AWS : SQS (Simple Queue Service) with NodeJS and AWS SDK
- AWS : Redshift data warehouse
- AWS : CloudFormation
- AWS : CloudFormation Bootstrap UserData/Metadata
- AWS : CloudFormation - Creating an ASG with rolling update
- AWS : Cloudformation Cross-stack reference
- AWS : OpsWorks
- AWS : Network Load Balancer (NLB) with Autoscaling group (ASG)
- AWS CodeDeploy : Deploy an Application from GitHub
- AWS EC2 Container Service (ECS)
- AWS EC2 Container Service (ECS) II
- AWS Hello World Lambda Function
- AWS Lambda Function Q & A
- AWS Node.js Lambda Function & API Gateway
- AWS API Gateway endpoint invoking Lambda function
- AWS API Gateway invoking Lambda function with Terraform
- AWS API Gateway invoking Lambda function with Terraform - Lambda Container
- Amazon Kinesis Streams
- AWS: Kinesis Data Firehose with Lambda and ElasticSearch
- Amazon DynamoDB
- Amazon DynamoDB with Lambda and CloudWatch
- Loading DynamoDB stream to AWS Elasticsearch service with Lambda
- Amazon ML (Machine Learning)
- Simple Systems Manager (SSM)
- AWS : RDS Connecting to a DB Instance Running the SQL Server Database Engine
- AWS : RDS Importing and Exporting SQL Server Data
- AWS : RDS PostgreSQL & pgAdmin III
- AWS : RDS PostgreSQL 2 - Creating/Deleting a Table
- AWS : MySQL Replication : Master-slave
- AWS : MySQL backup & restore
- AWS RDS : Cross-Region Read Replicas for MySQL and Snapshots for PostgreSQL
- AWS : Restoring Postgres on EC2 instance from S3 backup
- AWS : Q & A
- AWS : Security
- AWS : Security groups vs. network ACLs
- AWS : Scaling-Up
- AWS : Networking
- AWS : Single Sign-on (SSO) with Okta
- AWS : JIT (Just-in-Time) with Okta
Ph.D. / Golden Gate Ave, San Francisco / Seoul National Univ / Carnegie Mellon / UC Berkeley / DevOps / Deep Learning / Visualization