Amazon Web Services (AWS)
Perform the following steps to deploy FortiGuest on AWS.
- Obtain the file FortiGuest_VM64_AWS-v1.3.0-[build0xxx].aws.zip from Fortinet.
- Install or gain access to the AWS CLI. See Get started with the AWS CLI.
- Configure the AWS CLI as per your access requirements. These are some sample values that you must replace with the relevant ones.
$ aws configure
AWS Access Key ID [None]: AKIAIOSFODNN7EXAMPLE
AWS Secret Access Key [None]: YEXAMPLEKEY
Default region name [None]: us-west-2
Default output format [None]: json - Create an IAM role named vmimport. This operation requires IAM permissions.
cat <<EOF > trust-policy.json
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Allow",
"Principal": { "Service": "vmie.amazonaws.com" },
"Action": "sts:AssumeRole",
"Condition": {
"StringEquals":{
"sts:Externalid": "vmimport"
}
}
}
]
}
EOF
aws iam create-role --role-name vmimport --assume-role-policy-document file://trust-policy.json- Create a policy and attach it to an Amazon S3 bucket.
cat <<EOF > role-policy.json
{
"Version":"2012-10-17",
"Statement":[
{
"Effect":"Allow",
"Action":[
"s3:GetBucketLocation",
"s3:GetObject",
"s3:ListBucket
],
"Resource":[
"arn:aws:s3:::$s3BacketName",
"arn:aws:s3:::$s3BacketName/*"
]
},
{
"Effect":"Allow",
"Action":[
"ec2:ModifySnapshotAttribute",
"ec2:CopySnapshot",
"ec2:RegisterImage",
"ec2:Describe*"
],
"Resource":"*"
}
]
}
EOF
aws iam put-role-policy --role-name vmimport --policy-name vmimport --policy-document file://role-policy.json
- Create a policy and attach it to an Amazon S3 bucket.
- Extract the file FortiGuest_VM64_AWS-v1.3.0-[build0xxx].aws.zip. Post extraction, you have the following files.
-
VHD - FortiGuest_VM64_AWS-v1.3.0-[build0xxx].vhd
-
Import script - import2awsimg.sh
Note: To import the VM, you must have read & write permissions to the Amazon bucket, EC2 Snapshot, and image create/import.