Skip to content

Commit

Permalink
Add RDS instance class
Browse files Browse the repository at this point in the history
  • Loading branch information
bporter816 committed Mar 29, 2024
1 parent 79d2de2 commit 64b4c09
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion rds_instances.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ func NewRDSInstances(repo *repo.RDS, app *Application, dbClusterId string) *RDSI
Table: ui.NewTable([]string{
"NAME",
"STATUS",
"CLASS",
"ENDPOINT",
}, 1, 0),
repo: repo,
Expand Down Expand Up @@ -72,13 +73,16 @@ func (r *RDSInstances) Render() {

var data [][]string
for _, v := range model {
var name, status, endpoint string
var name, status, class, endpoint string
if v.DBInstanceIdentifier != nil {
name = *v.DBInstanceIdentifier
}
if v.DBInstanceStatus != nil {
status = utils.AutoCase(*v.DBInstanceStatus)
}
if v.DBInstanceClass != nil {
class = *v.DBInstanceClass
}
if v.Endpoint != nil {
if v.Endpoint.Address != nil {
endpoint = *v.Endpoint.Address
Expand All @@ -90,6 +94,7 @@ func (r *RDSInstances) Render() {
data = append(data, []string{
name,
status,
class,
endpoint,
})
}
Expand Down

0 comments on commit 64b4c09

Please sign in to comment.