ExternalDockerCredentialOptions Struct
Options for defining credentials for a Docker Credential.
Example
ts
const dockerHubSecret = secretsmanager.Secret.fromSecretCompleteArn(
this,
'DHSecret',
'arn:aws:...'
);
// Only the image asset publishing actions will be granted read access to the secret.
const creds = pipelines.DockerCredential.dockerHub(dockerHubSecret, {
usages: [pipelines.DockerCredentialUsage.ASSET_PUBLISHING],
});
Properties
assumeRoleoptionalIRoleassume_roleoptionalIRoleassumeRoleoptionalIRoleAssumeRoleoptionalIRoleAssumeRoleoptionalIRole#An IAM role to assume prior to accessing the secret.
Default: none. The current execution role will be used.
secretPasswordFieldoptionalstringsecret_password_fieldoptionalstrsecretPasswordFieldoptionalStringSecretPasswordFieldoptionalstringSecretPasswordFieldoptional*string= 'secret'#The name of the JSON field of the secret which contains the secret/password.
secretUsernameFieldoptionalstringsecret_username_fieldoptionalstrsecretUsernameFieldoptionalStringSecretUsernameFieldoptionalstringSecretUsernameFieldoptional*string= 'username'#The name of the JSON field of the secret which contains the user/login name.
usagesoptionalDockerCredentialUsage[]usagesoptionaltyping.List[DockerCredentialUsage]usagesoptionalList<DockerCredentialUsage>UsagesoptionalDockerCredentialUsage[]Usagesoptional*[]DockerCredentialUsage#Defines which stages of the pipeline should be granted access to these credentials.
Default: all relevant stages (synth, self-update, asset publishing) are granted access.