autiam

command module
v0.0.0-...-9a0cb76 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 5, 2024 License: GPL-3.0 Imports: 10 Imported by: 0

README

autiam

Automate IAM Role token generation on EC2 instances. Simply run eval $(autiam <role>).

How it works

This simply automates the process described by AWS to obtain access tokens that grant a certain IAM Role permission on EC2 instances.

The program generates the following output:

admin@ec2:~$ autiam role
export AWS_ACCESS_KEY_ID=...
export AWS_SECRET_ACCESS_KEY=...
export AWS_SESSION_TOKEN=...

Where 'role' would be replaced by the actual role's name you want to assume, and the actual tokens would replace the ellipsis. By running the output through eval you automatically set them as environment variables.

Why

I run restic to back up data to S3 buckets on EC2 instances and use temporary IAM Role tokens, this automates the process of obtaining them so I can focus on running the restic commands.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL