forked from Ivasoft/drone-docker
Add support for multiple Buildkit secrets with env vars or files as source (#359)
This commit is contained in:
committed by
GitHub
parent
d0b9da388f
commit
94f2f970db
@@ -254,6 +254,16 @@ func main() {
|
||||
Usage: "secret key value pair eg id=MYSECRET",
|
||||
EnvVar: "PLUGIN_SECRET",
|
||||
},
|
||||
cli.StringSliceFlag{
|
||||
Name: "secrets-from-env",
|
||||
Usage: "secret key value pair eg secret_name=secret",
|
||||
EnvVar: "PLUGIN_SECRETS_FROM_ENV",
|
||||
},
|
||||
cli.StringSliceFlag{
|
||||
Name: "secrets-from-file",
|
||||
Usage: "secret key value pairs eg secret_name=/path/to/secret",
|
||||
EnvVar: "PLUGIN_SECRETS_FROM_FILE",
|
||||
},
|
||||
cli.StringFlag{
|
||||
Name: "drone-card-path",
|
||||
Usage: "card path location to write to",
|
||||
@@ -298,6 +308,8 @@ func run(c *cli.Context) error {
|
||||
Link: c.String("link"),
|
||||
NoCache: c.Bool("no-cache"),
|
||||
Secret: c.String("secret"),
|
||||
SecretEnvs: c.StringSlice("secrets-from-env"),
|
||||
SecretFiles: c.StringSlice("secrets-from-file"),
|
||||
AddHost: c.StringSlice("add-host"),
|
||||
Quiet: c.Bool("quiet"),
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user