CLI tool to update ~/.aws/config with all accounts and permission sets defined in AWS SSO

aws-sso-profiles

Generate or update ~/.aws/config with a profile for each SSO account you have access to, by using an existing AWS SSO session.

Bootstrap

Create a bootstrap aws config file in the current directory:

[profile bootstrap]
sso_start_url = https://COMPANY.awsapps.com/start
sso_region = us-east-1
sso_account_id =
sso_role_name =
AWS_CONFIG_FILE=$PWD/bootstrap AWS_PROFILE=bootstrap aws sso login
go run github.com/sparebank1utvikling/aws-sso-profiles@main

Result

Your ~/.aws/config will now contain all permission sets you have access to via this SSO start URL, in addition to your existing config:

[profile account1-role1]
sso_start_url  = https://COMPANY.awsapps.com/start
sso_account_id = 123456789012
sso_role_name  = Role1
sso_region     = us-east-1
region         = us-east-1

[profile account2-role2]
sso_start_url  = https://COMPANY.awsapps.com/start
sso_account_id = 123456789012
sso_role_name  = role2
sso_region     = us-east-1
region         = us-east-1

[profile existing]
region         = us-east-1
...
Similar Resources

CLI for exploring AWS EC2 Spot inventory. Inspect AWS Spot instance types, saving, price, and interruption frequency.

spotinfo The spotinfo is a command-line tool that helps you determine AWS Spot instance types with the least chance of interruption and provides the s

Dec 19, 2022

A tool to manage all your boilerplate from cli and generate files for you !

A tool to manage all your boilerplate from cli and generate files for you !

Jul 20, 2022

A CLI tool to display all dependencies or dependents of an object in a Kubernetes cluster.

kube-lineage A CLI tool to display all dependencies or dependents of an object in a Kubernetes cluster. Usage $ kube-lineage clusterrole system:metric

Jan 5, 2023

Azure-nuke - The CLI tool to delete all resources in an Azure Account

azure-nuke This repository would contain the CLI tool to delete all resources in

Jun 8, 2022

Github-org-diff - Simple CLI tool to check a diff between 2 branches of all org repos

github-org-diff Simple CLI tool to list org repos that have diff between dev and

Jan 25, 2022

A minimal CLI tool to enable (or disable) dependabot for all your repositories

Enable Dependabot A minimal CLI tool to enable (or disable) dependabot for all your repositories. Installation Install via Go go get -v github.com/RiR

Feb 10, 2022

Nebula Diagnosis CLI Tool is an information diagnosis cli tool for the nebula service and the node to which the service belongs.

Nebula Diagnosis CLI Tool is an information diagnosis cli tool for the nebula service and the node to which the service belongs.

Jan 12, 2022

Query, update and convert data structures from the command line. Comparable to jq/yq but supports JSON, TOML, YAML, XML and CSV with zero runtime dependencies.

Query, update and convert data structures from the command line. Comparable to jq/yq but supports JSON, TOML, YAML, XML and CSV with zero runtime dependencies.

dasel Dasel (short for data-selector) allows you to query and modify data structures using selector strings. Comparable to jq / yq, but supports JSON,

Jan 2, 2023

A CLI tool to manage and streamline AWS ECS deployments

Outback CLI 🦘 About The Project Outback is CLI tool written in Go to help streamline the process of deploying containerized applications to AWS Elast

Dec 8, 2021
Opinionated CLI app for AWS SSO made in Golang!
Opinionated CLI app for AWS SSO made in Golang!

aws-sso-creds AWS SSO Creds Table of Contents About The Project Built With Instalation Static From source Usage Contributing License Contact Acknowled

Aug 17, 2022
Tnbassist - A CLI tool for thenewboston blockchain to perform various mundane tasks like taking daily accounts backup

TNB Assist is a CLI (Command Line Interface) tool for thenewboston blockchain to perform various mundane tasks like taking daily accounts backup, computing statistics, etc easier.

Feb 14, 2022
GitHub CLI extension to clone (or update) all repositories in an Organization, with the ability to filter via search queries.

gh-org-repo-sync GitHub CLI extension to clone all repositories in an Organization, with the ability to filter via search queries. If a local clone al

Nov 2, 2022
slotchmod changes file permission with a slot.
slotchmod changes file permission with a slot.

slotchmod Table of Contents 1. Usage 2. Installation 3. Key input 4. Help slotchmod changes file permission with a slot. This is a useful tool when yo

Dec 13, 2022
Envp - ENVP is cli wrapper that sets environment variables by profile when you execute the command line

ENVP ENVP is cli wrapper that sets environment variables by profile based config

Nov 7, 2022
Newyearify - Update the copyright year in all of your GitHub repos

new_yearify Update the copyright year in all of your GitHub repositories. How do

Feb 6, 2022
Ghissue - This repo contains a github issue parser, that is useful for Enterprise Github accounts.

Ghissue - This repo contains a github issue parser, that is useful for Enterprise Github accounts. Sometimes is needed to parse the content of the issue for some data extraction or statistics purposes.

Feb 6, 2022
dots is CLI tool to build, version and publish config file bundles.

dots-cli dots is CLI tool to build, version and publish config file bundles. TODO (shared): Writing comprehensive documentation Designing landing page

Aug 24, 2022
Automatically sets up command line flags based on struct fields and tags.
Automatically sets up command line flags based on struct fields and tags.

Commandeer Commandeer sets up command line flags based on struct fields and tags. Do you... like to develop Go apps as libraries with tiny main packag

Dec 1, 2022
A simple CLI app to update dynamic DNS settings for your CloudFlare account

Cloudflare Dynamic DNS Updater (Go) written by Darren Rambaud Why? A simple CLI app to update dynamic DNS settings for your CloudFlare account. Useful

Nov 28, 2021