@@ -86,6 +86,8 @@ Metadata:
86
86
- SecretsBucketRegion
87
87
- SecretsBucketEncryption
88
88
- ArtifactsBucket
89
+ - ArtifactsBucketRegion
90
+ - ArtifactsS3ACL
89
91
- AuthorizedUsersUrl
90
92
- BootstrapScriptUrl
91
93
- AgentEnvFileUrl
@@ -399,6 +401,24 @@ Parameters:
399
401
Type : String
400
402
Default : " "
401
403
404
+ ArtifactsBucketRegion :
405
+ Description : Optional - Region for the ArtifactsBucket. If blank the bucket's region is dynamically discovered.
406
+ Type : String
407
+ Default : " "
408
+
409
+ ArtifactsS3ACL :
410
+ Description : Optional - ACL to use for S3 artifact uploads
411
+ Type : String
412
+ AllowedValues :
413
+ - " private"
414
+ - " public-read"
415
+ - " public-read-write"
416
+ - " authenticated-read"
417
+ - " aws-exec-read"
418
+ - " bucket-owner-read"
419
+ - " bucket-owner-full-control"
420
+ Default : " private"
421
+
402
422
BootstrapScriptUrl :
403
423
Description : Optional - HTTPS or S3 URL for a script to run on each instance during boot
404
424
Type : String
@@ -879,13 +899,13 @@ Conditions:
879
899
880
900
UseInstanceType7 :
881
901
!Not [ !Equals [ !Select [ "6", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
882
-
902
+
883
903
UseInstanceType8 :
884
904
!Not [ !Equals [ !Select [ "7", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
885
-
905
+
886
906
UseInstanceType9 :
887
907
!Not [ !Equals [ !Select [ "8", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
888
-
908
+
889
909
UseInstanceType10 :
890
910
!Not [ !Equals [ !Select [ "9", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
891
911
@@ -894,13 +914,13 @@ Conditions:
894
914
895
915
UseInstanceType12 :
896
916
!Not [ !Equals [ !Select [ "11", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
897
-
917
+
898
918
UseInstanceType13 :
899
919
!Not [ !Equals [ !Select [ "12", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
900
920
901
921
UseInstanceType14 :
902
922
!Not [ !Equals [ !Select [ "13", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
903
-
923
+
904
924
UseInstanceType15 :
905
925
!Not [ !Equals [ !Select [ "14", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
906
926
@@ -909,13 +929,13 @@ Conditions:
909
929
910
930
UseInstanceType17 :
911
931
!Not [ !Equals [ !Select [ "16", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
912
-
932
+
913
933
UseInstanceType18 :
914
934
!Not [ !Equals [ !Select [ "17", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
915
-
935
+
916
936
UseInstanceType19 :
917
937
!Not [ !Equals [ !Select [ "18", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
918
-
938
+
919
939
UseInstanceType20 :
920
940
!Not [ !Equals [ !Select [ "19", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
921
941
@@ -927,7 +947,7 @@ Conditions:
927
947
928
948
UseInstanceType23 :
929
949
!Not [ !Equals [ !Select [ "22", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
930
-
950
+
931
951
UseInstanceType24 :
932
952
!Not [ !Equals [ !Select [ "23", !Split [ ",", !Join [ ",", [ !Ref InstanceTypes, "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", ""] ] ] ], ""] ]
933
953
@@ -1556,6 +1576,9 @@ Resources:
1556
1576
$Env:BUILDKITE_SCALE_IN_IDLE_PERIOD="${ScaleInIdlePeriod}"
1557
1577
$Env:BUILDKITE_SECRETS_BUCKET="${LocalSecretsBucket}"
1558
1578
$Env:BUILDKITE_SECRETS_BUCKET_REGION="${LocalSecretsBucketRegion}"
1579
+ $Env:BUILDKITE_ARTIFACTS_BUCKET="${ArtifactsBucket}"
1580
+ $Env:BUILDKITE_S3_DEFAULT_REGION="${LocalArtifactsBucketRegion}"
1581
+ $Env:BUILDKITE_S3_ACL="${ArtifactsS3ACL}"
1559
1582
$Env:BUILDKITE_AGENT_TOKEN_PATH="${AgentTokenPath}"
1560
1583
$Env:BUILDKITE_AGENTS_PER_INSTANCE="${AgentsPerInstance}"
1561
1584
$Env:BUILDKITE_AGENT_ENDPOINT="${AgentEndpoint}"
@@ -1590,6 +1613,13 @@ Resources:
1590
1613
- CreateSecretsBucket
1591
1614
- !Ref " AWS::Region"
1592
1615
- !Ref SecretsBucketRegion
1616
+ LocalArtifactsBucketRegion : !If
1617
+ - UseArtifactsBucket
1618
+ - !If
1619
+ - !Equals [ !Ref ArtifactsBucketRegion, "" ]
1620
+ - !Ref " AWS::Region"
1621
+ - !Ref ArtifactsBucketRegion
1622
+ - !Ref " AWS::Region"
1593
1623
AgentTokenPath : !If
1594
1624
- UseCustomerManagedParameterPath
1595
1625
- !Ref BuildkiteAgentTokenParameterStorePath
@@ -1632,6 +1662,9 @@ Resources:
1632
1662
BUILDKITE_SCALE_IN_IDLE_PERIOD="${ScaleInIdlePeriod}" \
1633
1663
BUILDKITE_SECRETS_BUCKET="${LocalSecretsBucket}" \
1634
1664
BUILDKITE_SECRETS_BUCKET_REGION="${LocalSecretsBucketRegion}" \
1665
+ BUILDKITE_ARTIFACTS_BUCKET="${ArtifactsBucket}" \
1666
+ BUILDKITE_S3_DEFAULT_REGION="${LocalArtifactsBucketRegion}" \
1667
+ BUILDKITE_S3_ACL="${ArtifactsS3ACL}" \
1635
1668
BUILDKITE_AGENT_TOKEN_PATH="${AgentTokenPath}" \
1636
1669
BUILDKITE_AGENTS_PER_INSTANCE="${AgentsPerInstance}" \
1637
1670
BUILDKITE_AGENT_ENDPOINT="${AgentEndpoint}" \
@@ -1678,6 +1711,13 @@ Resources:
1678
1711
- CreateSecretsBucket
1679
1712
- !Ref " AWS::Region"
1680
1713
- !Ref SecretsBucketRegion
1714
+ LocalArtifactsBucketRegion : !If
1715
+ - UseArtifactsBucket
1716
+ - !If
1717
+ - !Equals [ !Ref ArtifactsBucketRegion, "" ]
1718
+ - !Ref " AWS::Region"
1719
+ - !Ref ArtifactsBucketRegion
1720
+ - !Ref " AWS::Region"
1681
1721
AgentTokenPath : !If
1682
1722
- UseCustomerManagedParameterPath
1683
1723
- !Ref BuildkiteAgentTokenParameterStorePath
0 commit comments