Navigate to the awk/AMI/s3 directory.
1.
cd aws/AMI/s3
Initialize terraform.
2.
terraform init
Get terraform packages and validate the templates.
3.
terraform get
terraform validate
Plan and apply to create an S3 bucket DynamoDB table.
4.
terraform plan
terraform apply -auto-approve
Note:
Save the state file to the same bucket for later creating the S3 stack using AWS
console
Create the AMI
Three files within the aws/AMI folder contains variables in the standard format of
variableName = "value". Each variable within the three variable files should be updated to
reflect your environment.
Navigate to the aws/AMI directory.
1.
cd ~/aws/AMI
Update the variables in the following files with suitable values:
2.
•
linuxvm/terraform.tfvars
•
linuxvm/bucket.tf
•
ami/bucket.tf
Run the bash script create_ami.sh with the -c argument to specify the workspace
3.
name.
bash create_ami.sh -c nnSCZ840
The script runs a series of terraform commands to create the AMI.
Refer to the README file for more information.
For instructions on using an AMI, see
Delete the AMI
If you no longer need the AMI, follow these steps to delete it.
Create and Deploy OCSBC Instances on EC2
Use an AMI
in the AWS documentation.
Chapter 7
7-21
Need help?
Do you have a question about the Netra Server X5-2 and is the answer not in the manual?
Questions and answers