Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] Add ability to filter accounts for repo/$PWD #283

Open
KennyS-Cox opened this issue Feb 4, 2025 · 0 comments
Open

[FEATURE] Add ability to filter accounts for repo/$PWD #283

KennyS-Cox opened this issue Feb 4, 2025 · 0 comments

Comments

@KennyS-Cox
Copy link

Feature Request 🚀

Ability to have a file in repo/directory that alks can use to filter accounts for alks sessions open --filter-file or something similar.

example file: <repo>/.alks

[AccountNames]
awsgdmowner
awsgdmownernp

Describe Your Feature Request

Similar to #185, I have a bunch of accounts and roles. Would be nice to be able to filter accounts to the repo I am currently using so when I run alks sessions open --filter-file or something similar, it only shows the accounts that repo will use. Should read the file in $PWD if exists and filter accordingly.

Example before:

➜  ~ alks sessions open
ALKS v3.21.1
? Please select an ALKS account/role (Use arrow keys)
  ************/ALKSAdmin - awsdesignatedcr :: Admin 
  ************/ALKSAdmin - awsdesignatedcrnp :: Admin 
  ************/ALKSAdmin - awsdesignateddescription :: Admin 
  ************/ALKSAdmin - awsdesignateddescriptionnp :: Admin 
  ************/ALKSAdmin - awsgdmowner :: Admin 
  ************/ALKSSsmUser - awsgdmowner :: SsmUser 
❯ ************/ALKSAdmin - awsgdmownernp :: Admin 
  ************/ALKSAdmin - awslifecycledecorators :: Admin 
  ************/ALKSAdmin - awslifecycledecoratorsnp :: Admin 
  ************/ALKSAdmin - awsscs :: Admin 
  ************/ALKSAdmin - awsscsnp :: Admin 
  ************/ALKSAdmin - awssiren :: Admin 
  ************/ALKSReadOnly - awssiren :: ReadOnly 
  ************/ALKSAdmin - awssirennp :: Admin 
  ************/ALKSAdmin - awswholesaleinvfound :: Admin 

Example after:

➜  ~ alks sessions open --filter-file
ALKS v3.21.1
? Please select an ALKS account/role (Use arrow keys)
  ************/ALKSAdmin - awsgdmowner :: Admin 
  ************/ALKSSsmUser - awsgdmowner :: SsmUser 
❯ ************/ALKSAdmin - awsgdmownernp :: Admin 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant