Restructuring role, working through Allow Role to Identity functionality

This commit is contained in:
2026-04-03 22:36:14 -04:00
parent 73d1e7967d
commit f8d3d3fcff
3 changed files with 133 additions and 5 deletions

View File

@@ -109,6 +109,11 @@ func assumeRole(args []string) {
os.Exit(1)
}
if apiresponse.Status != "success" {
fmt.Printf("Error assuming role: %s\n", apiresponse.Message)
os.Exit(1)
}
home, err := os.UserHomeDir()
if err != nil {
panic(err)
@@ -223,6 +228,8 @@ func roleMain(args []string) {
}
subcommand := args[0]
fmt.Println("Sub command", subcommand)
cmd := findCommand(subcommand, roleCommands)
if cmd == nil {
fmt.Println("Error: unknown command:", subcommand)