Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[dirty] d/aws_s3_bucket: get default encryption configuration #2300

Closed
wants to merge 275 commits into from
Closed
Show file tree
Hide file tree
Changes from 3 commits
Commits
Show all changes
275 commits
Select commit Hold shift + click to select a range
45818cc
Update CHANGELOG.md
radeksimko Nov 15, 2017
230fe59
Merge pull request #2301 from jurajseffer/codebuild_ip_range
radeksimko Nov 15, 2017
2e52315
Merge pull request #2207 from bflad/ec2-iam-role-permissions
radeksimko Nov 15, 2017
04b31ad
Merge pull request #2250 from pdecat/patch-1
radeksimko Nov 15, 2017
84dcbf9
Merge pull request #2262 from seriousben/support-update-cf-stack-tags
radeksimko Nov 15, 2017
036a42e
Update CHANGELOG.md
radeksimko Nov 15, 2017
22b2c68
Adjust aws_dynamodb_table CreateTable LimitExceededException handling…
bflad Nov 15, 2017
93b7cbc
Update CHANGELOG.md
radeksimko Nov 15, 2017
7960eea
Add arn attribute to aws_elb resource (#2272)
bflad Nov 15, 2017
c303d11
Update CHANGELOG.md
radeksimko Nov 15, 2017
d7b303e
Add arn attribute to aws_ebs_volume resource and datasource (#2271)
bflad Nov 15, 2017
7c14a34
Update CHANGELOG.md
radeksimko Nov 15, 2017
ccf26c7
New Data Source: aws_instances
radeksimko Nov 13, 2017
b6b32d5
Merge pull request #2266 from terraform-providers/f-d-instances
radeksimko Nov 15, 2017
b59fa96
Update CHANGELOG.md
radeksimko Nov 15, 2017
d7658da
#2217: added acceptance test for basic case
trung Nov 16, 2017
6a2fdd9
#2217: documentation
trung Nov 16, 2017
0f72ca7
t/lb_target_group: Add missing matcher in acc test
radeksimko Nov 16, 2017
a56feae
t/ecr_lifecycle_policy: Randomize repo name
radeksimko Nov 16, 2017
51651a5
Fix bug that not waiting batch_job_queue deleted.
shibataka000 Nov 16, 2017
cf42ac1
r/aws_lb: mark subnets as ForceNew for network load balancers (#2310)
catsby Nov 16, 2017
db3c17e
Update CHANGELOG.md
catsby Nov 16, 2017
b4d7dd7
Update acceptance test with new attributes
darend Nov 16, 2017
33df43f
r/lb+elb: Suppress diff for LBs w/ empty name (#2314)
radeksimko Nov 16, 2017
aab14f9
Make acceptance test more thorough
radeksimko Nov 16, 2017
77cd556
r/lb_target_group: Respect threshold & error on interval change for T…
radeksimko Nov 16, 2017
20ad210
Merge pull request #2323 from terraform-providers/b-nlb-tg-fields
radeksimko Nov 16, 2017
d6d2147
New Resource: aws_cognito_user_pool (#1419)
Ninir Nov 16, 2017
0f3fee0
Update CHANGELOG.md
Ninir Nov 16, 2017
009addb
v1.3.0
Nov 16, 2017
4181add
Cleanup after v1.3.0 release
Nov 16, 2017
906fbd6
docs: Fix layout for cognito_user_pool
radeksimko Nov 16, 2017
55a6023
Merge pull request #2326 from terraform-providers/docs-fix-cognito-up…
radeksimko Nov 16, 2017
57ab3e1
Merge pull request #2315 from terraform-providers/b-lb-tf-add-missing…
radeksimko Nov 16, 2017
a301ad9
Update CHANGELOG.md
radeksimko Nov 16, 2017
7e5babe
Use 2 spaces
atsushi-ishibashi Nov 17, 2017
52d6d64
Merge pull request #2317 from terraform-providers/t-ecr-randomize
radeksimko Nov 17, 2017
e5af306
Merge pull request #2334 from atsushi-ishibashi/docs-athena-named-query
radeksimko Nov 17, 2017
e3276b8
Merge pull request #2322 from shibataka000/issue-2044
radeksimko Nov 17, 2017
d315184
Update CHANGELOG.md
radeksimko Nov 17, 2017
06602d7
r/security_group_rule: parse description correctly (#1959)
jaymecd Nov 17, 2017
18f7a4d
Update CHANGELOG.md
radeksimko Nov 17, 2017
1e9de9f
docs: Fix rds_cluster DS title (#2340)
radeksimko Nov 17, 2017
84c69f1
r/ecs_task_definition: Fix equivalency comparator (#2339)
radeksimko Nov 17, 2017
27e2f31
Update CHANGELOG.md
radeksimko Nov 17, 2017
b615080
bump aws-sdk-go to v1.12.30
Puneeth-n Nov 18, 2017
2df5e5c
docs: fix typo in api gw method and integration response (#2355)
vladgolubev Nov 20, 2017
133bf51
Fixed Cognito Lambda Config Validation for optional ARN configurations
Ninir Nov 20, 2017
bb41adf
efs_mount_target.html.markdown: Clarified use of attributes
Ninir Nov 20, 2017
2b11fc7
Merge pull request #2370 from Ninir/b-cognito-lambda-validation
Ninir Nov 20, 2017
f9c57c8
Update CHANGELOG.md
Ninir Nov 20, 2017
5a0e84b
r/aws_cognito_identity_pool_roles_attachment: Fix typo "authenticated…
atsushi-ishibashi Nov 20, 2017
d699223
Update CHANGELOG.md
Ninir Nov 20, 2017
0788318
v1.3.1
Nov 20, 2017
1939123
Cleanup after v1.3.1 release
Nov 20, 2017
55d333c
Merge pull request #2359 from Puneeth-n/chore/aws-sdk-go-1.12.30
Ninir Nov 21, 2017
f3a37e4
r/aws_ssm_maintenance_window_target: Change MaxItems of targets (#2361)
atsushi-ishibashi Nov 21, 2017
4d36e9d
Update CHANGELOG.md
Ninir Nov 21, 2017
60f5428
Add aws-sdk-go/service/swf package
Nov 19, 2017
6c763c1
Support Step Function UpdateStateMachine call
Puneeth-n Nov 17, 2017
b08c231
Fixes nil check for EmailSubjectByLink in flattenCognitoUserPoolVerif…
mil Nov 21, 2017
215add6
Add mutex and retry for method response
betabandido Nov 21, 2017
8baadc9
Merge pull request #2395 from mil/fix-bug-with-cognito-userpool-email…
Ninir Nov 21, 2017
027524d
Update CHANGELOG.md
Ninir Nov 21, 2017
a61a091
Merge pull request #2393 from betabandido/fix/method-response-conflict
Ninir Nov 21, 2017
2a3b63a
Update CHANGELOG.md
Ninir Nov 21, 2017
e97ad73
Merge pull request #2209 from sagansystems/nat-gateway-patch
Ninir Nov 21, 2017
0daea38
Update CHANGELOG.md
Ninir Nov 21, 2017
ce4c83b
Fixed the default values in the lb_target_group document
jun06t Nov 21, 2017
3ea4a48
Merge pull request #2387 from jun06t/docs
Ninir Nov 22, 2017
f416a86
Merge pull request #2349 from Puneeth-n/chore/aws-sfn-update-state-ma…
Ninir Nov 22, 2017
d90c792
Update CHANGELOG.md
Ninir Nov 22, 2017
32a8888
Merge pull request #2364 from robinjoseph08/vendor-swf
Ninir Nov 22, 2017
637f6c7
Bump AWS SDK to v1.12.32
bflad Nov 22, 2017
0f5ac18
r/aws_instance: Set placement_group in state on read if available (#2…
bflad Nov 22, 2017
133c319
Update CHANGELOG.md
Ninir Nov 22, 2017
d354311
Remove redundant words in main README
jckuester Nov 24, 2017
415c51b
Merge pull request #2424 from cloudetc/fix/main-readme
Ninir Nov 24, 2017
94c2bbb
Update CHANGELOG.md
radeksimko Nov 26, 2017
19503d1
Merge pull request #2404 from bflad/aws-sdk-v1_12_32
radeksimko Nov 26, 2017
d548f22
Fix typo
atsushi-ishibashi Nov 26, 2017
3873b93
Merge pull request #2430 from atsushi-ishibashi/fix_api_gateway_method
radeksimko Nov 26, 2017
d572fb0
Update CHANGELOG.md
radeksimko Nov 26, 2017
8e5fcea
Modify validate, make replication_group_id to lowercase
atsushi-ishibashi Nov 27, 2017
eaf24b4
Fix spelling of "character"
rbirkby Nov 27, 2017
e326aff
Update CHANGELOG.md
catsby Nov 29, 2017
aba52d6
v1.4.0
Nov 29, 2017
60482bb
Cleanup after v1.4.0 release
Nov 29, 2017
7a65b85
aws/structure: add canonicalXML helper function (#2464)
catsby Nov 29, 2017
647f8d6
vendor: github.com/aws/aws-sdk-go/...@v1.12.35
radeksimko Nov 29, 2017
635cf32
vendor: github.com/aws/aws-sdk-go/service/mq@v1.12.35
radeksimko Nov 29, 2017
e10d275
Merge pull request #2465 from terraform-providers/vendor-aws-v1.12.35
radeksimko Nov 29, 2017
bd0b46f
New Resource: aws_mq_configuration
radeksimko Nov 12, 2017
6106552
New Resource: aws_mq_broker
radeksimko Nov 29, 2017
04a46fb
docs: Add MQ docs
radeksimko Nov 29, 2017
84f9d90
Merge pull request #2466 from terraform-providers/f-r-mq
radeksimko Nov 29, 2017
7a43723
Update CHANGELOG.md
radeksimko Nov 29, 2017
840a82b
v1.5.0
Nov 29, 2017
f81adc4
Cleanup after v1.5.0 release
Nov 29, 2017
1aba033
docs: Fix incomplete example of mq_configuration
radeksimko Nov 29, 2017
12ac5c6
Merge pull request #2470 from terraform-providers/docs-mq-cfg-fix
radeksimko Nov 29, 2017
7006c61
r/aws_rds_cluster: Update database_name documentation with link to RD…
bflad Nov 30, 2017
29ab7c4
Add media* package
atsushi-ishibashi Nov 30, 2017
6336713
Fix typo
a-suenami Nov 30, 2017
250ae06
Minor fix for elasticache_replication_group documentation
sumodirjo Nov 30, 2017
f894d41
Bump aws-sdk-go to v1.12.37
Puneeth-n Nov 30, 2017
7a14b01
Merge pull request #2444 from rbirkby/patch-1
radeksimko Nov 30, 2017
5f7af0d
Merge pull request #2480 from bflad/rds_cluster_database_name_limits
radeksimko Nov 30, 2017
7a7c612
Merge pull request #2485 from a-suenami/fix-typo
radeksimko Nov 30, 2017
505e175
Merge pull request #2486 from sumodirjo/master
radeksimko Nov 30, 2017
a7bcbd3
Merge pull request #2481 from atsushi-ishibashi/verndor-awssdk-media-…
radeksimko Nov 30, 2017
c7e3842
Merge pull request #2490 from Puneeth-n/chore/bump-aws-sdk-go-v1.12.37
radeksimko Nov 30, 2017
65f18f2
Docs fix: name is an attribute on lb target group
Nov 30, 2017
3bad035
Bump aws-sdk-go to v1.12.38
Puneeth-n Nov 30, 2017
61aed01
vendor: New service guardduty@v1.12.38
bflad Nov 30, 2017
cf83b11
r/elasticache_parameter_group: Add StateFunc to make name lowercase (…
atsushi-ishibashi Nov 30, 2017
948fc87
Update CHANGELOG.md
Ninir Nov 30, 2017
82c0bb4
Merge pull request #2503 from bflad/guardduty-v1.12.38
radeksimko Dec 1, 2017
c7ecc4f
Merge pull request #2500 from Puneeth-n/chore/bump-aws-sdk-go-v1.12.38
radeksimko Dec 1, 2017
99beed7
Corrected depends_on entry for EIP
Dec 1, 2017
7b808e4
Merge pull request #2496 from genevievelesperance/patch-1
radeksimko Dec 1, 2017
fa56bc4
Merge pull request #2257 from atsushi-ishibashi/issue2205
radeksimko Dec 2, 2017
3067767
Update CHANGELOG.md
radeksimko Dec 2, 2017
5138547
Merge pull request #2432 from atsushi-ishibashi/lowercase-elasticache_rg
radeksimko Dec 2, 2017
9432309
Update CHANGELOG.md
radeksimko Dec 2, 2017
eb21ac4
Reflect reviews
atsushi-ishibashi Dec 2, 2017
8921adf
vendor: appsync@v1.12.38
atsushi-ishibashi Dec 3, 2017
a5a5795
r/aws_placement_group: Update documentation to omit incorrect "The on…
bflad Dec 4, 2017
7b7f9f9
Updated required go version in readme from 1.8 to 1.9
jfharden Dec 4, 2017
a4fd204
Merge pull request #2523 from jfharden/fix-required-version-in-readme
Ninir Dec 4, 2017
2cb7e2d
Merge pull request #2521 from bflad/placement_group_docs
Ninir Dec 4, 2017
41ca4e3
Merge pull request #2518 from atsushi-ishibashi/vendor-appsync-v1.12.38
radeksimko Dec 4, 2017
86f6c5b
Bump aws-sdk-go to v1.12.39
Puneeth-n Dec 4, 2017
8f92e28
Merge pull request #2299 from atsushi-ishibashi/issue2294
radeksimko Dec 4, 2017
7dbbf91
Update CHANGELOG.md
radeksimko Dec 4, 2017
f5409e0
Merge pull request #2527 from Puneeth-n/chore/aws-sdk-go-1.12.39
radeksimko Dec 4, 2017
401dc01
New Datasource: aws_network_interface (#2316)
atsushi-ishibashi Dec 4, 2017
390ad04
Update CHANGELOG.md
radeksimko Dec 4, 2017
01ff393
New Resource: aws_appautoscaling_scheduled_action (#2231)
atsushi-ishibashi Dec 4, 2017
3ba4448
Update CHANGELOG.md
radeksimko Dec 4, 2017
2aa59d4
Update CHANGELOG.md
radeksimko Dec 4, 2017
4b3ff9e
Merge pull request #2371 from Ninir/d-efs-mount-target-attributes
Ninir Dec 4, 2017
dcb44db
New Resource: aws_dx_connection_association (#2360)
atsushi-ishibashi Dec 4, 2017
168287a
Update CHANGELOG.md
radeksimko Dec 4, 2017
b40e6ef
AWS Lambda concurrency (#2504)
Puneeth-n Dec 5, 2017
899d387
Update CHANGELOG.md
radeksimko Dec 5, 2017
844674a
Cognito User Pool documentation clarifications (#2428)
ctranstrum Dec 5, 2017
7483013
Downgrade ES domains to save money 💰
radeksimko Dec 5, 2017
4d07a34
Downgrade EMR to save money 💰
radeksimko Dec 5, 2017
5d48470
r/aws_ecs_cluster: Add arn attribute
bflad Dec 5, 2017
96ff0c7
Downsize RDS to save money 💰
radeksimko Dec 5, 2017
7b094f0
Replace service-role policy w/ custom
radeksimko Dec 5, 2017
26d9e1d
ECS Fargate Support (#2483)
apricote Dec 5, 2017
4d7ccce
Update CHANGELOG.md
radeksimko Dec 5, 2017
f27e24d
Merge pull request #2555 from terraform-providers/t-downsize-rds
radeksimko Dec 5, 2017
45c95ba
Merge pull request #2548 from terraform-providers/t-downgrade-es-domains
radeksimko Dec 5, 2017
3b57263
Merge pull request #2549 from terraform-providers/t-downgrade-emr
radeksimko Dec 5, 2017
fc7bff3
Merge pull request #2552 from bflad/aws_ecs_cluster_arn
Ninir Dec 6, 2017
1df1483
Update CHANGELOG.md
Ninir Dec 6, 2017
bd0e513
Add sweeper for IAM Server Certificates
radeksimko Dec 6, 2017
68dd30e
r/aws_db_instance: Move create/delete/update pending states to their …
bflad Dec 6, 2017
af10cf3
Update CHANGELOG.md
radeksimko Dec 6, 2017
67c33cd
test/aws_config_delivery_channel: Add missing dependencies
radeksimko Dec 6, 2017
9168557
Update CHANGELOG.md
radeksimko Dec 6, 2017
5976a41
Add servicediscovery@v1.12.41 (#2562)
atsushi-ishibashi Dec 6, 2017
8cf1d04
Merge pull request #2243 from bflad/aws_cloudwatch_logs_resource_policy
radeksimko Dec 6, 2017
e4ab178
Update CHANGELOG.md
radeksimko Dec 6, 2017
ff812a4
d/aws_instance: Set placement_group if available (#2400)
bflad Dec 6, 2017
aff7ddf
Update CHANGELOG.md
radeksimko Dec 6, 2017
9cf398a
d/aws_elb r/aws_elb: #2004 review comments
bflad Dec 7, 2017
b90fb1a
Merge branch 'master' into elb_data_source
bflad Dec 7, 2017
3de6ff9
d/aws_elb: Fix documentation sidebar ordering after merging master wi…
bflad Dec 7, 2017
b7af9d4
Makefile: Add sweep target
bflad Dec 7, 2017
75be5d9
Update cognito_user_pool.markdown
Ninir Dec 7, 2017
c617ebc
Bump aws-sdk-go to v1.12.43
Puneeth-n Dec 7, 2017
4f997d1
Merge pull request #2583 from Puneeth-n/chore/aws-sdk-go-1.12.43
Ninir Dec 7, 2017
c2b778c
Merge pull request #2566 from terraform-providers/t-sweep-iam-server-…
radeksimko Dec 8, 2017
869ecbd
Merge pull request #2567 from terraform-providers/t-awsconfig-deps
radeksimko Dec 8, 2017
2ef640a
Merge pull request #2004 from bflad/elb_data_source
radeksimko Dec 8, 2017
74bc076
Update CHANGELOG.md
radeksimko Dec 8, 2017
851b0e0
r/aws_elasticache_security_group: add import support (#2277)
bflad Dec 8, 2017
7c6bacb
Update CHANGELOG.md
radeksimko Dec 8, 2017
f9bcdc0
Merge pull request #2513 from rondemena/master
Ninir Dec 8, 2017
a52af9a
documentation: remove antislashes in page titles
Ninir Dec 8, 2017
00c2fe6
Added missing WARN debug lines when reading a non-existing resource
Ninir Dec 8, 2017
8a9e7ac
Removed <wbr> from documentation titles
Ninir Dec 8, 2017
d2ce778
r/mq_broker: Fix crash in hashing function
radeksimko Dec 8, 2017
e75e8f2
t/db_instance: Run acceptance tests in default region
radeksimko Dec 8, 2017
d69845e
vendor: Bump aws-sdk-go to v.1.12.44
bflad Dec 9, 2017
da97ea6
Merge pull request #2597 from Ninir/f-missing-debug-lines
Ninir Dec 9, 2017
e2b4e35
Merge pull request #2595 from Ninir/d-clean-titles
Ninir Dec 9, 2017
01e2af9
Merge pull request #2582 from terraform-providers/Ninir-patch-1
Ninir Dec 9, 2017
f901034
Add logs for iam server certificate delete conflict (#2533)
Dec 10, 2017
7cc930a
Fix test names
radeksimko Dec 10, 2017
5fc4c91
t/db_instance: Add test for EC2 classic
radeksimko Dec 10, 2017
37cb271
r/aws_sqs_queue_policy: Support import by queue URL (#2544)
bflad Dec 11, 2017
4de0ba4
Update CHANGELOG.md
radeksimko Dec 11, 2017
f413876
r/aws_elasticsearch_domain: Add LogPublishingOption (#2285)
atsushi-ishibashi Dec 11, 2017
881c998
Update CHANGELOG.md
radeksimko Dec 11, 2017
90347f6
Add force_destroy field to aws_athena_database (#2363)
betabandido Dec 11, 2017
862947e
Update CHANGELOG.md
radeksimko Dec 11, 2017
b48cf61
Merge pull request #2608 from bflad/aws-sdk-go-v1.12.44
radeksimko Dec 11, 2017
9a2ef7e
Add more example and missing field
lologhi Dec 11, 2017
97942bf
New Resource: aws_media_store_container (#2448)
atsushi-ishibashi Dec 11, 2017
0c0887c
Update CHANGELOG.md
radeksimko Dec 11, 2017
f4800f6
Add Redis AUTH, in-transit and at-rest encryption (#2090)
nathanielks Dec 11, 2017
005acbf
docs/elasticache_replication_group: Add missing fields
radeksimko Dec 12, 2017
6eb922a
Update CHANGELOG.md
radeksimko Dec 12, 2017
edb26df
r/aws_dynamodb_table: Ensure ttl is properly read (#2452)
bflad Dec 12, 2017
3661be9
Update CHANGELOG.md
radeksimko Dec 12, 2017
cb45e68
Merge pull request #2638 from terraform-providers/docs-elasticache-rg
radeksimko Dec 12, 2017
3bafb07
Bump aws-sdk-go to v.1.12.45
Puneeth-n Dec 12, 2017
3fc4ab2
New Resource: PublicDnsNamespace (#2569)
atsushi-ishibashi Dec 12, 2017
8c6a711
Update CHANGELOG.md
radeksimko Dec 12, 2017
380d33e
Merge pull request #2575 from bflad/make-sweep
radeksimko Dec 12, 2017
fd11302
Merge pull request #2639 from Puneeth-n/chore/aws-sdk-go-1.12.45
radeksimko Dec 12, 2017
cffdb25
Merge pull request #2623 from lologhi/master
radeksimko Dec 12, 2017
9e849e9
New Resource: ServiceDiscovery PrivateDNS Namespace (#2589)
atsushi-ishibashi Dec 12, 2017
28edb4b
Update CHANGELOG.md
radeksimko Dec 12, 2017
bf70c19
Bump aws-sdk-go to v1.12.46
Puneeth-n Dec 13, 2017
5925b05
Merge pull request #2644 from Puneeth-n/chore/aws-sdk-go-1.12.46
radeksimko Dec 13, 2017
a09392a
Refactor refresh funcs to make them reusable
radeksimko Dec 5, 2017
a138f6f
Add sweeper for aws_db_instance
radeksimko Dec 5, 2017
0c07bc7
Merge pull request #2558 from terraform-providers/t-rds-sweepers
radeksimko Dec 13, 2017
51d5a15
Merge pull request #2618 from terraform-providers/t-db-instance-regio…
radeksimko Dec 13, 2017
20fd5ce
Merge pull request #2598 from terraform-providers/b-mq-broker-hash
radeksimko Dec 13, 2017
7af57be
Update CHANGELOG.md
radeksimko Dec 13, 2017
affe15c
Add vendoring for Amazon Lex
Dec 13, 2017
8994a34
Merge pull request #2650 from jzbruno/add_vendoring_for_lex
radeksimko Dec 13, 2017
a6d1266
r/aws_lb_target_group: various fixes to behavior based on protocol ty…
catsby Dec 14, 2017
eb1658b
Update CHANGELOG.md
catsby Dec 14, 2017
285fca8
Update docs for syntax lighlighting
kei-q Dec 15, 2017
6bd9216
Merge pull request #2675 from kei-q/enable-syntax-highlight
tombuildsstuff Dec 15, 2017
b835b45
Bump aws-sdk-go to v1.12.48
Puneeth-n Dec 16, 2017
f999f27
#2217: updated r/aws_s3_bucket to support default server side encrypt…
trung Nov 29, 2017
0a5c260
#2217: make fmt
trung Nov 29, 2017
c9254b7
#2217: wrote typical acceptance test
trung Dec 12, 2017
9cfd2fe
#2217: wrote additional acceptance test
trung Dec 12, 2017
39bf66a
#2217: re-enable default encryption after disabling in via UI
trung Dec 13, 2017
8b71af1
#2217: documentation
trung Dec 13, 2017
36a4c1f
#2217: fixed when encryption is AES256
trung Dec 14, 2017
c7838e5
s3: Add validation for SSE Algorithm and correct spelling
Dec 17, 2017
019e6e0
Merge branch 'trung-f-r-2217'
jen20 Dec 17, 2017
3ed24ce
Update CHANGELOG.md
jen20 Dec 17, 2017
7b9b3e1
Merge pull request #2687 from Puneeth-n/chore/bump-aws-sdk-go-v1.12.48
jen20 Dec 17, 2017
8a0f9b7
#2217: get default encryption configuration for s3 bucket data source
trung Nov 15, 2017
4c2fe29
#2217: added acceptance test for basic case
trung Nov 16, 2017
8e9dff4
#2217: documentation
trung Nov 16, 2017
53c0081
Merge branch 'f-d-2217' of github.com:trung/terraform-provider-aws in…
trung Dec 17, 2017
8da4d8b
additional acceptance tests
trung Dec 17, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
78 changes: 78 additions & 0 deletions aws/data_source_aws_s3_bucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,45 @@ func dataSourceAwsS3Bucket() *schema.Resource {
Type: schema.TypeString,
Required: true,
},
"server_side_encryption_configuration": {
Type: schema.TypeList,
MaxItems: 1,
Computed: true,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"enabled": {
Type: schema.TypeBool,
Computed: true,
},
"rule": {
Type: schema.TypeList,
MaxItems: 1,
Computed: true,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"apply_server_side_encryption_by_default": {
Type: schema.TypeList,
MaxItems: 1,
Computed: true,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{
"kms_master_key_id": {
Type: schema.TypeString,
Computed: true,
},
"sse_algorithm": {
Type: schema.TypeString,
Computed: true,
},
},
},
},
},
},
},
},
},
},
"arn": {
Type: schema.TypeString,
Computed: true,
Expand Down Expand Up @@ -70,6 +109,45 @@ func dataSourceAwsS3BucketRead(d *schema.ResourceData, meta interface{}) error {
return err
}

if err := bucketEncryption(d, bucket, conn); err != nil {
return err
}

return nil
}

func bucketEncryption(data *schema.ResourceData, bucket string, conn *s3.S3) error {
input := &s3.GetBucketEncryptionInput{
Bucket: aws.String(bucket),
}
output, err := conn.GetBucketEncryption(input)
if err != nil {
if isAWSErr(err, "ServerSideEncryptionConfigurationNotFoundError", "encryption configuration was not found") {
log.Printf("[DEBUG] Default encryption is not enabled for %s", bucket)
data.Set("server_side_encryption_configuration", []map[string]interface{}{
{
"enabled": false,
},
})
return nil
} else {
return err
}
}
if ruleCount := len(output.ServerSideEncryptionConfiguration.Rules); ruleCount != 1 {
return fmt.Errorf("expect one rule returned but there are %d rules. Changes required in the data source to support this", ruleCount)
}
defaultRuleConfiguration := output.ServerSideEncryptionConfiguration.Rules[0].ApplyServerSideEncryptionByDefault
defaultRule := make([]map[string]interface{}, 1)
defaultRule[0]["kms_master_key_id"] = aws.StringValue(defaultRuleConfiguration.KMSMasterKeyID)
defaultRule[0]["sse_algorithm"] = aws.StringValue(defaultRuleConfiguration.SSEAlgorithm)

encryptionConfiguration := make([]map[string]interface{}, 1)
encryptionConfiguration[0]["enabled"] = true
encryptionConfiguration[0]["rule"] = make([]map[string]interface{}, 1)
encryptionConfiguration[0]["rule"].(map[string]interface{})["apply_server_side_encryption_by_default"] = defaultRule

data.Set("server_side_encryption_configuration", encryptionConfiguration)
return nil
}

Expand Down
21 changes: 21 additions & 0 deletions aws/data_source_aws_s3_bucket_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,27 @@ func TestAccDataSourceS3Bucket_website(t *testing.T) {
})
}

func TestAccDataSourceS3Bucket_whenDefaultEncryptionNotEnabled(t *testing.T) {
rInt := acctest.RandInt()

resource.Test(t, resource.TestCase{
PreCheck: func() { testAccPreCheck(t) },
Providers: testAccProviders,
Steps: []resource.TestStep{
{
Config: testAccAWSDataSourceS3BucketConfig_basic(rInt),
Check: resource.ComposeTestCheckFunc(
testAccCheckAWSS3BucketExists("data.aws_s3_bucket.bucket"),
resource.TestCheckResourceAttr(
"data.aws_s3_bucket.bucket", "server_side_encryption_configuration.0.enabled", "false"),
resource.TestCheckResourceAttr(
"data.aws_s3_bucket.bucket", "server_side_encryption_configuration.0.rule.#", "0"),
),
},
},
})
}

func testAccAWSDataSourceS3BucketConfig_basic(randInt int) string {
return fmt.Sprintf(`
resource "aws_s3_bucket" "bucket" {
Expand Down
8 changes: 7 additions & 1 deletion website/docs/d/s3_bucket.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -69,4 +69,10 @@ The following attributes are exported:
* `hosted_zone_id` - The [Route 53 Hosted Zone ID](https://docs.aws.amazon.com/general/latest/gr/rande.html#s3_website_region_endpoints) for this bucket's region.
* `region` - The AWS region this bucket resides in.
* `website_endpoint` - The website endpoint, if the bucket is configured with a website. If not, this will be an empty string.
* `website_domain` - The domain of the website endpoint, if the bucket is configured with a website. If not, this will be an empty string. This is used to create Route 53 alias records.
* `website_domain` - The domain of the website endpoint, if the bucket is configured with a website. If not, this will be an empty string. This is used to create Route 53 alias records.
* `server_side_encryption_configuration` - The encryption configuration for the bucket
* `enabled` - True if default encryption is enabled, false otherwise
* `rule` - Only available if `enabled` is true
* `apply_server_side_encryption_by_default` - Details about the default encryption
* `kms_master_key_id` - AWS KMS Key Id that is used to encrypt in server side
* `sse_algorithm` - Encryption algorithm used. Possible values are `AES256` and `aws:kms`