Skip to content

Commit 4b8516f

Browse files
committed
feat: add mutableTags option to sync command
1 parent ddf4117 commit 4b8516f

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

cmd/dockersync/cmd/sync.go

+5-3
Original file line numberDiff line numberDiff line change
@@ -70,10 +70,12 @@ var syncCmd = &cobra.Command{
7070

7171
source, _ := cmd.Flags().GetString("source")
7272
targets, _ := cmd.Flags().GetStringSlice("targets")
73+
mutableTags, _ := cmd.Flags().GetStringSlice("mutableTags")
7374

7475
cnf.Sync.Images = append(cnf.Sync.Images, syncImage{
75-
Source: source,
76-
Targets: targets,
76+
Source: source,
77+
Targets: targets,
78+
MutableTags: mutableTags,
7779
})
7880

7981
var registries []syncRegistry
@@ -181,7 +183,7 @@ func init() {
181183
syncCmd.MarkFlagRequired("source")
182184
syncCmd.MarkFlagRequired("targets")
183185

184-
syncCmd.Flags().StringP("mutableTags", "m", "", "Mutable tags")
186+
syncCmd.Flags().StringSliceP("mutableTags", "m", []string{}, "Mutable tags")
185187

186188
syncCmd.Flags().StringP("ecr-region", "", os.Getenv("AWS_REGION"), "AWS region for ECR")
187189

0 commit comments

Comments
 (0)