Skip to main content

AWS Credentials Setup using Access Keys

Create Policy with required permissions

Login to your AWS account and navigate to the IAM service.

  1. Click on Policies in the left menu and then Create policy in the top right corner.
  2. Select JSON in the Policy Editor section
  3. Paste the following policy into the JSON editor:
    {
    "Version": "2012-10-17",
    "Statement": [
    {
    "Sid": "ec2",
    "Effect": "Allow",
    "Action": [
    "ec2:*"
    ],
    "Resource": "*"
    },
    {
    "Sid": "elb",
    "Effect": "Allow",
    "Action": [
    "elasticloadbalancing:*"
    ],
    "Resource": "*"
    },
    {
    "Sid": "IAMStar",
    "Effect": "Allow",
    "Action": [
    "iam:GetUser",
    "iam:SimulatePrincipalPolicy",
    "iam:CreatePolicy",
    "iam:DeletePolicy",
    "iam:GetPolicy",
    "iam:ListPolicies",
    "iam:GetPolicyVersion",
    "iam:CreateRole",
    "iam:DeleteRole",
    "iam:GetRole",
    "iam:ListRoles",
    "iam:ListRolePolicies",
    "iam:AttachRolePolicy",
    "iam:DetachRolePolicy",
    "iam:GetRolePolicy",
    "iam:CreateInstanceProfile",
    "iam:DeleteInstanceProfile",
    "iam:GetInstanceProfile",
    "iam:AddRoleToInstanceProfile",
    "iam:RemoveRoleFromInstanceProfile",
    "iam:CreateServiceLinkedRole"
    ],
    "Resource": "*"
    },
    {
    "Sid": "IAMPassRoleEBsInstance",
    "Effect": "Allow",
    "Action": [
    "iam:PassRole"
    ],
    "Resource": "arn:aws:iam::*:role/AnkraEbsInstanceRole*"
    }
    ]
    }
  4. Next give the policy a Name and Description
  5. Click Create policy

You can now use this policy with an existing user or create a new user and attach this policy.

Create IAM user

Login to your AWS account and navigate to the IAM service.

  1. Click on Users in the left menu and then Create user in the top right corner.
  2. Provide the user with the newly created policy.

Create Access Key

Login to your AWS account and navigate to the IAM service.

  1. Click on Users in the left menu and then click on the user you want to connect to Ankra.
  2. Click on the Security credentials tab and then Create access key under Access keys.
  3. Select Third Party Services, tick the Confirmation and then click Next.
  4. Copy the Access key ID and Secret access key saving them somewhere safe. You will need them later.