From 9c46e62c7f7a294d30a6403db707842e62f3f5b8 Mon Sep 17 00:00:00 2001 From: Ivan Pedrazas Date: Fri, 16 Dec 2016 05:35:59 +0000 Subject: [PATCH] prefix key added --- main.go | 6 ++++++ plugin.go | 1 + 2 files changed, 7 insertions(+) diff --git a/main.go b/main.go index c10189a..b065343 100644 --- a/main.go +++ b/main.go @@ -73,6 +73,11 @@ func main() { Usage: "add the secrets used in the values field", EnvVar: "PLUGIN_SECRETS,SECRETS", }, + cli.StringSliceFlag{ + Name: "prefix", + Usage: "Prefix for all the secrets", + EnvVar: "PLUGIN_PREFIX,PREFIX", + }, } if err := app.Run(os.Args); err != nil { logrus.Fatal(err) @@ -96,6 +101,7 @@ func run(c *cli.Context) error { Debug: c.Bool("debug"), DryRun: c.Bool("dry-run"), Secrets: c.StringSlice("secrets"), + Prefix: c.String("prefix"), }, } if plugin.Config.Debug { diff --git a/plugin.go b/plugin.go index a93c1d2..eaaa562 100644 --- a/plugin.go +++ b/plugin.go @@ -28,6 +28,7 @@ type ( Debug bool `json:"debug"` DryRun bool `json:"dry_run"` Secrets []string `json:"secrets"` + Prefix string `json:"prefix"` } // Plugin default Plugin struct {