blib/lib/Paws/CodeDeploy/CreateDeployment.pm untested

filter: Statementstmt 0.0% 0 / 29 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 2 Podpod n/a totaltotal 0.0% 0 / 31 CC 1 SCAR 6.9
CC
1
Cov
0%
BEGIN
2.0
BEGIN
2.0
CRAP 2.0
1  
2 package Paws::CodeDeploy::CreateDeployment;
3 use Moose;
4 has ApplicationName => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'applicationName' , required => 1);
5 has AutoRollbackConfiguration => (is => 'ro', isa => 'Paws::CodeDeploy::AutoRollbackConfiguration', traits => ['NameInRequest'], request_name => 'autoRollbackConfiguration' );
6 has DeploymentConfigName => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'deploymentConfigName' );
7 has DeploymentGroupName => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'deploymentGroupName' );
8 has Description => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'description' );
9 has FileExistsBehavior => (is => 'ro', isa => 'Str', traits => ['NameInRequest'], request_name => 'fileExistsBehavior' );
10 has IgnoreApplicationStopFailures => (is => 'ro', isa => 'Bool', traits => ['NameInRequest'], request_name => 'ignoreApplicationStopFailures' );
11 has Revision => (is => 'ro', isa => 'Paws::CodeDeploy::RevisionLocation', traits => ['NameInRequest'], request_name => 'revision' );
12 has TargetInstances => (is => 'ro', isa => 'Paws::CodeDeploy::TargetInstances', traits => ['NameInRequest'], request_name => 'targetInstances' );
13 has UpdateOutdatedInstancesOnly => (is => 'ro', isa => 'Bool', traits => ['NameInRequest'], request_name => 'updateOutdatedInstancesOnly' );
14  
15 use MooseX::ClassAttribute;
16  
17 class_has _api_call => (isa => 'Str', is => 'ro', default => 'CreateDeployment');
18 class_has _returns => (isa => 'Str', is => 'ro', default => 'Paws::CodeDeploy::CreateDeploymentOutput');
19 class_has _result_key => (isa => 'Str', is => 'ro');
20 1;
21  
22 ### main pod documentation begin ###
23  
24 =head1 NAME
25  
26 Paws::CodeDeploy::CreateDeployment - Arguments for method CreateDeployment on L<Paws::CodeDeploy>
27  
28 =head1 DESCRIPTION
29  
30 This class represents the parameters used for calling the method CreateDeployment on the
31 L<AWS CodeDeploy|Paws::CodeDeploy> service. Use the attributes of this class
32 as arguments to method CreateDeployment.
33  
34 You shouldn't make instances of this class. Each attribute should be used as a named argument in the call to CreateDeployment.
35  
36 =head1 SYNOPSIS
37  
38 my $codedeploy = Paws->service('CodeDeploy');
39 my $CreateDeploymentOutput = $codedeploy->CreateDeployment(
40 ApplicationName => 'MyApplicationName',
41 AutoRollbackConfiguration => {
42 Enabled => 1, # OPTIONAL
43 Events => [
44 'DEPLOYMENT_FAILURE',
45 ... # values: DEPLOYMENT_FAILURE, DEPLOYMENT_STOP_ON_ALARM, DEPLOYMENT_STOP_ON_REQUEST
46 ], # OPTIONAL
47 }, # OPTIONAL
48 DeploymentConfigName => 'MyDeploymentConfigName', # OPTIONAL
49 DeploymentGroupName => 'MyDeploymentGroupName', # OPTIONAL
50 Description => 'MyDescription', # OPTIONAL
51 FileExistsBehavior => 'DISALLOW', # OPTIONAL
52 IgnoreApplicationStopFailures => 1, # OPTIONAL
53 Revision => {
54 AppSpecContent => {
55 Content => 'MyRawStringContent', # OPTIONAL
56 Sha256 => 'MyRawStringSha256', # OPTIONAL
57 }, # OPTIONAL
58 GitHubLocation => {
59 CommitId => 'MyCommitId', # OPTIONAL
60 Repository => 'MyRepository', # OPTIONAL
61 }, # OPTIONAL
62 RevisionType =>
63 'S3', # values: S3, GitHub, String, AppSpecContent; OPTIONAL
64 S3Location => {
65 Bucket => 'MyS3Bucket', # OPTIONAL
66 BundleType => 'tar', # values: tar, tgz, zip, YAML, JSON; OPTIONAL
67 ETag => 'MyETag', # OPTIONAL
68 Key => 'MyS3Key', # OPTIONAL
69 Version => 'MyVersionId', # OPTIONAL
70 }, # OPTIONAL
71 String => {
72 Content => 'MyRawStringContent', # OPTIONAL
73 Sha256 => 'MyRawStringSha256', # OPTIONAL
74 }, # OPTIONAL
75 }, # OPTIONAL
76 TargetInstances => {
77 AutoScalingGroups => [ 'MyAutoScalingGroupName', ... ], # OPTIONAL
78 Ec2TagSet => {
79 Ec2TagSetList => [
80 [
81 {
82 Key => 'MyKey', # OPTIONAL
83 Type => 'KEY_ONLY'
84 , # values: KEY_ONLY, VALUE_ONLY, KEY_AND_VALUE; OPTIONAL
85 Value => 'MyValue', # OPTIONAL
86 },
87 ...
88 ],
89 ...
90 ], # OPTIONAL
91 }, # OPTIONAL
92 TagFilters => [
93 {
94 Key => 'MyKey', # OPTIONAL
95 Type => 'KEY_ONLY'
96 , # values: KEY_ONLY, VALUE_ONLY, KEY_AND_VALUE; OPTIONAL
97 Value => 'MyValue', # OPTIONAL
98 },
99 ...
100 ],
101 }, # OPTIONAL
102 UpdateOutdatedInstancesOnly => 1, # OPTIONAL
103 );
104  
105 # Results:
106 my $DeploymentId = $CreateDeploymentOutput->DeploymentId;
107  
108 # Returns a L<Paws::CodeDeploy::CreateDeploymentOutput> object.
109  
110 Values for attributes that are native types (Int, String, Float, etc) can passed as-is (scalar values). Values for complex Types (objects) can be passed as a HashRef. The keys and values of the hashref will be used to instance the underlying object.
111 For the AWS API documentation, see L<https://docs.aws.amazon.com/goto/WebAPI/codedeploy/CreateDeployment>
112  
113 =head1 ATTRIBUTES
114  
115  
116 =head2 B<REQUIRED> ApplicationName => Str
117  
118 The name of an AWS CodeDeploy application associated with the IAM user
119 or AWS account.
120  
121  
122  
123 =head2 AutoRollbackConfiguration => L<Paws::CodeDeploy::AutoRollbackConfiguration>
124  
125 Configuration information for an automatic rollback that is added when
126 a deployment is created.
127  
128  
129  
130 =head2 DeploymentConfigName => Str
131  
132 The name of a deployment configuration associated with the IAM user or
133 AWS account.
134  
135 If not specified, the value configured in the deployment group is used
136 as the default. If the deployment group does not have a deployment
137 configuration associated with it, C<CodeDeployDefault>.C<OneAtATime> is
138 used by default.
139  
140  
141  
142 =head2 DeploymentGroupName => Str
143  
144 The name of the deployment group.
145  
146  
147  
148 =head2 Description => Str
149  
150 A comment about the deployment.
151  
152  
153  
154 =head2 FileExistsBehavior => Str
155  
156 Information about how AWS CodeDeploy handles files that already exist
157 in a deployment target location but weren't part of the previous
158 successful deployment.
159  
160 The C<fileExistsBehavior> parameter takes any of the following values:
161  
162 =over
163  
164 =item *
165  
166 DISALLOW: The deployment fails. This is also the default behavior if no
167 option is specified.
168  
169 =item *
170  
171 OVERWRITE: The version of the file from the application revision
172 currently being deployed replaces the version already on the instance.
173  
174 =item *
175  
176 RETAIN: The version of the file already on the instance is kept and
177 used as part of the new deployment.
178  
179 =back
180  
181  
182 Valid values are: C<"DISALLOW">, C<"OVERWRITE">, C<"RETAIN">
183  
184 =head2 IgnoreApplicationStopFailures => Bool
185  
186 If true, then if an C<ApplicationStop>, C<BeforeBlockTraffic>, or
187 C<AfterBlockTraffic> deployment lifecycle event to an instance fails,
188 then the deployment continues to the next deployment lifecycle event.
189 For example, if C<ApplicationStop> fails, the deployment continues with
190 C<DownloadBundle>. If C<BeforeBlockTraffic> fails, the deployment
191 continues with C<BlockTraffic>. If C<AfterBlockTraffic> fails, the
192 deployment continues with C<ApplicationStop>.
193  
194 If false or not specified, then if a lifecycle event fails during a
195 deployment to an instance, that deployment fails. If deployment to that
196 instance is part of an overall deployment and the number of healthy
197 hosts is not less than the minimum number of healthy hosts, then a
198 deployment to the next instance is attempted.
199  
200 During a deployment, the AWS CodeDeploy agent runs the scripts
201 specified for C<ApplicationStop>, C<BeforeBlockTraffic>, and
202 C<AfterBlockTraffic> in the AppSpec file from the previous successful
203 deployment. (All other scripts are run from the AppSpec file in the
204 current deployment.) If one of these scripts contains an error and does
205 not run successfully, the deployment can fail.
206  
207 If the cause of the failure is a script from the last successful
208 deployment that will never run successfully, create a new deployment
209 and use C<ignoreApplicationStopFailures> to specify that the
210 C<ApplicationStop>, C<BeforeBlockTraffic>, and C<AfterBlockTraffic>
211 failures should be ignored.
212  
213  
214  
215 =head2 Revision => L<Paws::CodeDeploy::RevisionLocation>
216  
217 The type and location of the revision to deploy.
218  
219  
220  
221 =head2 TargetInstances => L<Paws::CodeDeploy::TargetInstances>
222  
223 Information about the instances that belong to the replacement
224 environment in a blue/green deployment.
225  
226  
227  
228 =head2 UpdateOutdatedInstancesOnly => Bool
229  
230 Indicates whether to deploy to all instances or only to instances that
231 are not running the latest application revision.
232  
233  
234  
235  
236 =head1 SEE ALSO
237  
238 This class forms part of L<Paws>, documenting arguments for method CreateDeployment in L<Paws::CodeDeploy>
239  
240 =head1 BUGS and CONTRIBUTIONS
241  
242 The source code is located here: L<https://github.com/pplu/aws-sdk-perl>
243  
244 Please report bugs to: L<https://github.com/pplu/aws-sdk-perl/issues>
245  
246 =cut
247