AddSecret
Method
func (ComposeFile) AddSecret( name string, options ...*AddSecretOptions,) ComposeFileSignature
method
AddSecret Adds a top-level secret definition to the Docker Compose file.
AddSecret( name string, options ...*AddSecretOptions,) ComposeFileParameters
namestringThe name of the secret.options...*AddSecretOptions Optional settings, described under Options.Options
Optional parameters are passed in a trailing options ...*AddSecretOptions argument.
File*stringThe path to the secret file.External*boolA value indicating whether the secret is managed outside the generated Compose file.Configurefunc(obj Secret) callbackAn optional callback for further secret customization.Returns
ComposeFile The updated Docker Compose file.
Returns a handle; failures surface later via Err().
Applies to
This method applies to the following types: