Class CreateCloudFormationLifecycleHook
java.lang.Object
org.craftercms.deployer.impl.lifecycle.AbstractLifecycleHook
org.craftercms.deployer.impl.lifecycle.aws.CreateCloudFormationLifecycleHook
- All Implemented Interfaces:
TargetLifecycleHook,InitializableByConfigBean
Implementation of
TargetLifecycleHook that creates a CloudFormation stack based on a provided
CloudFormation template file.- Author:
- avasquez
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected AwsClientBuilderConfigurerprotected static final Stringprotected static final Stringprotected static final Stringprotected static final Stringprotected List<software.amazon.awssdk.services.cloudformation.model.Capability> protected Stringprotected Stringprotected Collection<software.amazon.awssdk.services.cloudformation.model.Parameter> protected org.springframework.core.io.Resourceprotected org.springframework.core.io.ResourceFields inherited from class org.craftercms.deployer.impl.lifecycle.AbstractLifecycleHook
CONFIG_KEY_DISABLED, disabled, logger -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidcreateCloudFormationStack(software.amazon.awssdk.services.cloudformation.CloudFormationClient cloudFormation) voidvoiddoInit(org.apache.commons.configuration2.Configuration config) protected StringvoidsetTemplatesOverrideResource(org.springframework.core.io.Resource templatesOverrideResource) voidsetTemplatesResource(org.springframework.core.io.Resource templatesResource) Methods inherited from class org.craftercms.deployer.impl.lifecycle.AbstractLifecycleHook
execute, init
-
Field Details
-
CONFIG_KEY_STACK_NAME
- See Also:
-
CONFIG_KEY_TEMPLATE_FILENAME
- See Also:
-
CONFIG_KEY_TEMPLATE_PARAMS
- See Also:
-
CONFIG_KEY_STACK_CAPABILITIES
- See Also:
-
templatesResource
protected org.springframework.core.io.Resource templatesResource -
templatesOverrideResource
protected org.springframework.core.io.Resource templatesOverrideResource -
builderConfigurer
-
stackName
-
templateFilename
-
templateParams
-
stackCapabilities
-
-
Constructor Details
-
CreateCloudFormationLifecycleHook
public CreateCloudFormationLifecycleHook()
-
-
Method Details
-
setTemplatesResource
public void setTemplatesResource(org.springframework.core.io.Resource templatesResource) -
setTemplatesOverrideResource
public void setTemplatesOverrideResource(org.springframework.core.io.Resource templatesOverrideResource) -
doInit
public void doInit(org.apache.commons.configuration2.Configuration config) throws org.craftercms.commons.config.ConfigurationException - Specified by:
doInitin classAbstractLifecycleHook- Throws:
org.craftercms.commons.config.ConfigurationException
-
doExecute
- Specified by:
doExecutein classAbstractLifecycleHook- Throws:
DeployerException
-
createCloudFormationStack
protected void createCloudFormationStack(software.amazon.awssdk.services.cloudformation.CloudFormationClient cloudFormation) throws DeployerException - Throws:
DeployerException
-
getTemplateBody
- Throws:
DeployerException
-