ElasticBeanstalkDeployAction Class
CodePipeline action to deploy an AWS ElasticBeanstalk Application.
Example
ts
const sourceOutput = new codepipeline.Artifact();
const targetBucket = new s3.Bucket(this, 'MyBucket');
const pipeline = new codepipeline.Pipeline(this, 'MyPipeline');
const deployAction = new codepipeline_actions.ElasticBeanstalkDeployAction({
actionName: 'ElasticBeanstalkDeploy',
input: sourceOutput,
environmentName: 'envName',
applicationName: 'appName',
});
const deployStage = pipeline.addStage({
stageName: 'Deploy',
actions: [deployAction],
});
python
source_output = codepipeline.Artifact()
target_bucket = s3.Bucket(self, "MyBucket")
pipeline = codepipeline.Pipeline(self, "MyPipeline")
deploy_action = codepipeline_actions.ElasticBeanstalkDeployAction(
action_name="ElasticBeanstalkDeploy",
input=source_output,
environment_name="envName",
application_name="appName"
)
deploy_stage = pipeline.add_stage(
stage_name="Deploy",
actions=[deploy_action]
)
java
Artifact sourceOutput = new Artifact();
Bucket targetBucket = new Bucket(this, "MyBucket");
Pipeline pipeline = new Pipeline(this, "MyPipeline");
ElasticBeanstalkDeployAction deployAction = ElasticBeanstalkDeployAction.Builder.create()
.actionName("ElasticBeanstalkDeploy")
.input(sourceOutput)
.environmentName("envName")
.applicationName("appName")
.build();
IStage deployStage = pipeline.addStage(StageOptions.builder()
.stageName("Deploy")
.actions(List.of(deployAction))
.build());
csharp
// Install: dotnet add package Amazon.CDK.Lib
var sourceOutput = new Artifact();
var targetBucket = new Bucket(this, "MyBucket");
var pipeline = new Pipeline(this, "MyPipeline");
var deployAction = new ElasticBeanstalkDeployAction(new ElasticBeanstalkDeployActionProps {
ActionName = "ElasticBeanstalkDeploy",
Input = sourceOutput,
EnvironmentName = "envName",
ApplicationName = "appName"
});
var deployStage = pipeline.AddStage(new StageOptions {
StageName = "Deploy",
Actions = new [] { deployAction }
});
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
sourceOutput := codepipeline.NewArtifact()
targetBucket := s3.NewBucket(this, jsii.String("MyBucket"))
pipeline := codepipeline.NewPipeline(this, jsii.String("MyPipeline"))
deployAction := codepipeline_actions.NewElasticBeanstalkDeployAction(&ElasticBeanstalkDeployActionProps{
ActionName: jsii.String("ElasticBeanstalkDeploy"),
Input: sourceOutput,
EnvironmentName: jsii.String("envName"),
ApplicationName: jsii.String("appName"),
})
deployStage := pipeline.AddStage(&StageOptions{
StageName: jsii.String("Deploy"),
Actions: []IAction{
deployAction,
},
})
Initializer
ts
new ElasticBeanstalkDeployAction(props: ElasticBeanstalkDeployActionProps)
python
ElasticBeanstalkDeployAction(props: ElasticBeanstalkDeployActionProps)
java
new ElasticBeanstalkDeployAction(ElasticBeanstalkDeployActionProps props)
csharp
new ElasticBeanstalkDeployAction(ElasticBeanstalkDeployActionProps props)
go
NewElasticBeanstalkDeployAction(Props ElasticBeanstalkDeployActionProps)
Properties
actionPropertiesActionPropertiesaction_propertiesActionPropertiesactionPropertiesActionPropertiesActionPropertiesActionPropertiesActionPropertiesActionPropertiesrequired#The simple properties of the Action, like its Owner, name, etc.
Note that this accessor will be called before the bind callback.
Methods
bind(scope: Construct, stage: IStage, options: ActionBindOptions): ActionConfigdef bind(self, scope: Construct, stage: IStage, options: ActionBindOptions) -> ActionConfigpublic ActionConfig bind(Construct scope, IStage stage, ActionBindOptions options)public ActionConfig Bind(Construct scope, IStage stage, ActionBindOptions options)func Bind(Scope Construct, Stage IStage, Options ActionBindOptions) ActionConfig#The callback invoked when this Action is added to a Pipeline.
onStateChange(name: string, target?: IRuleTarget, options?: RuleProps): Ruledef on_state_change(self, name: str, target: typing.Optional[IRuleTarget] = None, options: typing.Optional[RuleProps] = None) -> Rulepublic Rule onStateChange(String name, IRuleTarget target, RuleProps options)public Rule OnStateChange(string name, IRuleTarget? target = null, RuleProps? options = null)func OnStateChange(Name *string, Target IRuleTarget, Options RuleProps) Rule#Creates an Event that will be triggered whenever the state of this Action changes.