1 réponse
- Le plus récent
- Le plus de votes
- La plupart des commentaires
1
You can directly provide the parameter values to the stack being deployed using the parameterOverrides
attribute (see the API documentation for details).
new CloudFormationCreateReplaceChangeSetAction({ actionName: 'PrepareChanges', stackName: 'my-stack', changeSetName: 'StagedChangeSet', adminPermissions: true, templatePath: sourceOutput.atPath('cloudformation/cf-test.yaml'), runOrder: 1, parameterOverrides: { 'AppDeployBucket' : 'your-value', 'DatabaseNamespace' : 'your-value' } });
In the example above, the parameter names and values are hard-coded.
If you want to specify the parameters using an artifact file, use templateConfiguration
instead (documentation link):
new CloudFormationCreateReplaceChangeSetAction({ actionName: 'PrepareChanges', stackName: 'my-stack', changeSetName: 'StagedChangeSet', adminPermissions: true, templatePath: sourceOutput.atPath('cloudformation/cf-test.yaml'), runOrder: 1, templateConfiguration: sourceOutput.atPath('parameter-file.json'), });
The template configuration file should contain a JSON object that should look like this:
{ "Parameters": {...}, "Tags": {...}, "StackPolicy": {...} }
répondu il y a 2 ans
Contenus pertinents
- demandé il y a un an
- demandé il y a 2 mois
- demandé il y a un an
- Réponse acceptéedemandé il y a un an
- AWS OFFICIELA mis à jour il y a 2 ans
- AWS OFFICIELA mis à jour il y a 2 ans
- AWS OFFICIELA mis à jour il y a un an
- AWS OFFICIELA mis à jour il y a 2 ans