Skip to content

Commit

Permalink
feat(cloudwatch-alarms): add name property (rebuy-de#746)
Browse files Browse the repository at this point in the history
  • Loading branch information
hv202x1 authored and mrkenkeller committed Feb 26, 2022
1 parent 3c0dd54 commit 35bf791
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions resources/cloudwatch-alarms.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"github.com/aws/aws-sdk-go/aws"
"github.com/aws/aws-sdk-go/aws/session"
"github.com/aws/aws-sdk-go/service/cloudwatch"
"github.com/rebuy-de/aws-nuke/pkg/types"
)

type CloudWatchAlarm struct {
Expand Down Expand Up @@ -55,6 +56,11 @@ func (f *CloudWatchAlarm) Remove() error {
return err
}

func (f *CloudWatchAlarm) Properties() types.Properties {
return types.NewProperties().
Set("Name", f.alarmName)
}

func (f *CloudWatchAlarm) String() string {
return *f.alarmName
}

0 comments on commit 35bf791

Please sign in to comment.