Skip to content

Commit

Permalink
Adds dash cmd to view metrics
Browse files Browse the repository at this point in the history
  • Loading branch information
ipmb committed Apr 19, 2022
1 parent 1ffb79e commit c21fe80
Show file tree
Hide file tree
Showing 5 changed files with 663 additions and 1 deletion.
23 changes: 22 additions & 1 deletion app/app.go
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,14 @@ type Settings struct {
ARN string `json:"arn"`
Name string `json:"name"`
} `json:"cluster"`
LoadBalancer struct {
ARN string `json:"arn"`
Suffix string `json:"suffix"`
} `json:"load_balancer"`
TargetGroup struct {
ARN string `json:"arn"`
Suffix string `json:"suffix"`
} `json:"target_group"`
Domains []string `json:"domains"`
Shell struct {
Command string `json:"command"`
Expand Down Expand Up @@ -383,7 +391,20 @@ func (a *App) GetDeployStatus(buildARN string) (*DeployStatus, error) {
return &i.DeployStatus, nil
}

// LoadDeployStatus will set the app.DeployStatus value from DDB
// GetServices will get a list of current services from the deploy status
func (a *App) GetServices() ([]string, error) {
err := a.LoadDeployStatus()
if err != nil {
return nil, err
}
services := []string{}
for _, process := range a.DeployStatus.Processes {
services = append(services, process.Name)
}
return services, nil
}

// LoadDeployStatus will get the app.DeployStatus value from DDB
func (a *App) LoadDeployStatus() error {
if a.DeployStatus != nil {
return nil
Expand Down

0 comments on commit c21fe80

Please sign in to comment.