Skip to content

Commit

Permalink
tsh request ls truncate roles (#45516)
Browse files Browse the repository at this point in the history
Signed-off-by: Zac Bergquist <[email protected]>
Co-authored-by: Carlos Castro <[email protected]>
  • Loading branch information
zmb3 and carloscastrojumo authored Aug 15, 2024
1 parent 9f2227f commit e3a159f
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions tool/tsh/common/access_request.go
Original file line number Diff line number Diff line change
Expand Up @@ -356,14 +356,19 @@ func showRequestTable(cf *CLIConf, reqs []types.AccessRequest) error {
return reqs[i].GetCreationTime().After(reqs[j].GetCreationTime())
})

table := asciitable.MakeTable([]string{"ID", "User", "Roles"})
table := asciitable.MakeTable([]string{"ID", "User"})
table.AddColumn(asciitable.Column{
Title: "Roles",
MaxCellLength: 20,
FootnoteLabel: "[+]",
})
table.AddColumn(asciitable.Column{
Title: "Resources",
MaxCellLength: 20,
FootnoteLabel: "[+]",
})
table.AddFootnote("[+]",
"Requested resources truncated, use `tsh request show <request-id>` to view the full list")
"Columns are truncated, use 'tsh request show <request-id>' to view the full list")
table.AddColumn(asciitable.Column{Title: "Created At (UTC)"})
table.AddColumn(asciitable.Column{Title: "Request TTL"})
table.AddColumn(asciitable.Column{Title: "Session TTL"})
Expand Down

0 comments on commit e3a159f

Please sign in to comment.