Skip to main content

How Delegaris reaches AWS

Delegaris does everything in AWS itself, on behalf of the person who asked. The people using it need no AWS access of their own. This page explains the two layers of access involved, and the choices for each.

Two layers​

  1. The service's own identity (sometimes called the hub). This is who the Delegaris container is in AWS: an EC2 instance role, an ECS task role, an IAM user's keys, or an IAM Identity Center sign-in. On its own it can do almost nothing.
  2. A way into each managed account. For each AWS account you add, you choose how the service gets in. Normally it assumes a role, DelegarisRole, that you create in that account and that trusts the service's identity.
+----------------------+ sts:AssumeRole +------------------------+
| Delegaris container | ----------------> | DelegarisRole |
| (its own identity) | | in account 111111111111|
+----------------------+ +------------------------+
| sts:AssumeRole +------------------------+
+----------------------------> | DelegarisRole |
| in account 222222222222|
+------------------------+

The role in each account allows listing, starting, stopping and tagging the services you chose for that account, and nothing else. The service's identity needs only permission to assume that role, and to read AWS list prices for cost estimates.

Ways into an account​

When you add an account, the Access part of the dialog offers these choices:

ChoiceHow it worksBest for
Assume a role in the accountThe service assumes DelegarisRole in the account, created from the template Delegaris gives you. Actions show in that account's CloudTrail as the role session delegaris-<username>, so you can see who was behind each one.Normal use. Nothing secret is stored for the account.
Use the account's own access keysAn IAM user in that account with the same permissions, or temporary keys with their session token. The keys are stored with the account. CloudTrail shows the key's owner, not the person.Trying things out, or an account where you cannot create the role yet.
Through Identity CenterOnce the service has been signed in through IAM Identity Center, it gets temporary credentials for the account from a permission set you name. CloudTrail shows the person who signed the service in.Trying things out, and small teams. Only offered after an Identity Center sign-in.
Use the service's own credentialsNo role is assumed: the service's own identity is used directly.The one account the service's identity itself belongs to.

See Adding accounts for the dialog step by step.

The service's own identity​

The container finds its credentials the same way the AWS CLI does, and an administrator can override them from the web UI. The choices:

  • An IAM role on the EC2 instance, ECS task or EKS pod that runs it. Nothing to store or rotate, and the recommended choice for a shared production service. On EC2 with Docker, the instance's metadata hop limit has to be raised first; see Docker on EC2.
  • Access keys saved under Accounts in the web UI, or in the environment.
  • An IAM Identity Center sign-in from your start URL, done from the Accounts page.

The Accounts page shows at the top which identity is in use and where it came from, or, if there is none, why not and how to fix it. See The service's own identity.

The service's identity also does a few things of its own: it reads AWS list prices for cost estimates, and, if you set them up, uploads backups and the activity log to S3.

note

If every account is added with its own access keys or through Identity Center, the service does not need an identity of its own. The Accounts page says so calmly rather than raising an alarm. You still need one to assume roles, which is the recommended set-up.

What to set up, in order​

  1. Give the service an identity. On EC2, deploy iam/hub-role.yaml and attach its instance profile; see Member account role for its parameters.
  2. Sign in as an administrator and open Accounts. Check the top of the page shows The service signs in to AWS as and an ARN.
  3. Add an account, create DelegarisRole in it from the template the dialog gives you, then Test connection.
  4. Add access rules under Settings > Access so people can see and use what is in the account. Until there is a rule, only administrators see anything. See Access rules.

Next steps​