Skip to content

Commit c3f87b2

Browse files
Merge pull request #1094 from terraform-providers/release_merge_v3.81.0
Candidate for release_v3.81.0
2 parents b6df1c4 + e5faf85 commit c3f87b2

File tree

165 files changed

+4864
-590
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

165 files changed

+4864
-590
lines changed

CHANGELOG.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,23 @@
11
## 3.81.0 (Unreleased)
2+
3+
### Added
4+
- Support Token base security authentication
5+
- Support for Scheduled Autoscaling
6+
- Support for `dbVersion` field in Autonomous databases Container database resources
7+
- Support for Archive Log Backup and Point in time restore
8+
- Support resource discovery for `datacatalog` resources
9+
- Support resource discovery for `dataSafe` resources
10+
- Support resource discovery for `integration` resources
11+
- Support resource discovery for `marketplace` resources
12+
- Added resource discovery support for `oce` resources
13+
- Support resource discovery for `oda` resources
14+
- Support resource discovery for `datascience` resources
15+
- Support resource discovery for `oci_objectstorage_object`, `oci_objectstorage_object_lifecycle_policy`, `oci_objectstorage_preauthrequest` resources
16+
- Support restore from file for `kms` resources
17+
18+
### Fixed
19+
- Fixed plan failure in case of missing required attributes in resource discovery. Placeholder values will be added for missing required attributes and the attributes will be added to `lifecycle ignore_changes`
20+
221
## 3.80.0 (June 10, 2020)
322

423
### Added

examples/autoscaling/compute.tf

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,19 @@ resource "oci_core_instance_pool" "TFInstancePool" {
6969
}
7070
}
7171

72+
resource "oci_core_instance_pool" "TFInstancePoolForScheduledPolicy" {
73+
compartment_id = "${var.compartment_ocid}"
74+
instance_configuration_id = "${oci_core_instance_configuration.TFInstanceConfiguration.id}"
75+
size = 2
76+
state = "RUNNING"
77+
display_name = "TFInstancePoolForScheduledPolicy"
78+
79+
placement_configurations {
80+
availability_domain = "${data.oci_identity_availability_domain.AD.name}"
81+
primary_subnet_id = "${oci_core_subnet.ExampleSubnet.id}"
82+
}
83+
}
84+
7285
resource "oci_autoscaling_auto_scaling_configuration" "TFAutoScalingConfiguration" {
7386
compartment_id = "${var.compartment_ocid}"
7487
cool_down_in_seconds = "300"
@@ -127,3 +140,32 @@ resource "oci_autoscaling_auto_scaling_configuration" "TFAutoScalingConfiguratio
127140
type = "instancePool"
128141
}
129142
}
143+
144+
resource "oci_autoscaling_auto_scaling_configuration" "TFAutoScalingConfigurationScheduledPolicy" {
145+
compartment_id = "${var.compartment_ocid}"
146+
cool_down_in_seconds = "300"
147+
display_name = "TFAutoScalingConfigurationScheduledPolicy"
148+
is_enabled = "true"
149+
150+
policies {
151+
capacity {
152+
initial = "4"
153+
max = "4"
154+
min = "2"
155+
}
156+
157+
display_name = "TFScheduledPolicy"
158+
policy_type = "scheduled"
159+
160+
execution_schedule {
161+
expression = "0 15 10 ? * *"
162+
timezone = "UTC"
163+
type = "cron"
164+
}
165+
}
166+
167+
auto_scaling_resources {
168+
id = "${oci_core_instance_pool.TFInstancePoolForScheduledPolicy.id}"
169+
type = "instancePool"
170+
}
171+
}

examples/autoscaling/datasources.tf

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@ data "oci_autoscaling_auto_scaling_configuration" "TFAutoScalingConfigurationDat
4545
auto_scaling_configuration_id = "${oci_autoscaling_auto_scaling_configuration.TFAutoScalingConfiguration.id}"
4646
}
4747

48+
data "oci_autoscaling_auto_scaling_configuration" "TFAutoScalingConfigurationScheduledPolicyDatasource" {
49+
auto_scaling_configuration_id = "${oci_autoscaling_auto_scaling_configuration.TFAutoScalingConfigurationScheduledPolicy.id}"
50+
}
51+
4852
data "oci_autoscaling_auto_scaling_configurations" "TFAutoScalingConfigurationDatasources" {
4953
compartment_id = "${var.compartment_ocid}"
5054
display_name = "TFAutoScalingConfiguration"
@@ -61,14 +65,14 @@ data "oci_core_instance" "TFInstancePoolInstanceSingularDatasources" {
6165
instance_id = "${lookup(data.oci_core_instance_pool_instances.TFInstancePoolInstanceDatasources.instances[count.index], "id")}"
6266
}
6367

64-
output "Pooled instances private IPs" {
68+
output "Pooled_instances_private_IPs" {
6569
value = ["${data.oci_core_instance.TFInstancePoolInstanceSingularDatasources.*.private_ip}"]
6670
}
6771

68-
output "Pooled instances public IPs" {
72+
output "Pooled_instances_public_IPs" {
6973
value = ["${data.oci_core_instance.TFInstancePoolInstanceSingularDatasources.*.public_ip}"]
7074
}
7175

72-
output "Pooled instances hostname labels" {
76+
output "Pooled_instances_hostname_labels" {
7377
value = ["${data.oci_core_instance.TFInstancePoolInstanceSingularDatasources.*.hostname_label}"]
7478
}

examples/kms/data_sources.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ data "oci_kms_vault" "test_vault" {
1313
}
1414

1515
/*
16-
//if want to create a new vault
16+
//create a new vault
1717
resource "oci_kms_vault" "test_vault" {
1818
#Required
1919
compartment_id = "${var.compartment_id}"

examples/kms/key.tf

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,22 +13,32 @@ resource "oci_kms_key" "test_key" {
1313
length = "${var.key_key_shape_length}"
1414
}
1515

16-
//If using bucket to restore a key use below
16+
//If using object to restore a key use below
1717
/*restore_from_object_store {
1818
bucket = "${data.oci_objectstorage_object.key_backup_object.bucket}"
1919
destination = "${var.destination[0]}"
2020
namespace = "${data.oci_objectstorage_object.key_backup_object.namespace}"
2121
object = "${data.oci_objectstorage_object.key_backup_object.object}"
2222
}*/
2323

24-
2524
//If using Pre-authenticated-request to restore a key use below
2625
/*restore_from_object_store {
2726
destination = "${var.destination[1]}"
2827
uri = "${data.oci_objectstorage_preauthrequest.key_backup_preauthenticated_request}"
2928
}*/
3029

31-
restore_trigger = "${var.key_restore_trigger}"
30+
//If using file stored in object storage to restore a key use below
31+
/*restore_from_file {
32+
//Required
33+
restore_key_from_file_details = "${data.oci_objectstorage_object.key_backup_object.content}"
34+
content_length = "${data.oci_objectstorage_object.key_backup_object.content_length}"
35+
36+
//Optional
37+
content_md5 = "${data.oci_objectstorage_object.key_backup_object.content_md5}"
38+
}*/
39+
40+
//Flip the trigger when restore operation on key needs to be performed
41+
//restore_trigger = "${var.key_restore_trigger}"
3242
}
3343

3444
resource "oci_kms_key_version" "test_key_version" {

examples/kms/vault.tf

Lines changed: 20 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,20 +3,33 @@ resource "oci_kms_vault" "private-vault-kms" {
33

44
/*restore_from_object_store {
55
bucket = "${data.oci_objectstorage_object.vault_backup_object.bucket}"
6-
destination = "${var.destination.bucket}"
6+
destination = "${var.destination[0]}"
77
namespace = "${data.oci_objectstorage_object.vault_backup_object.namespace}"
88
object = "${data.oci_objectstorage_object.vault_backup_object.object}"
99
}*/
1010

1111
//If restoring using a pre-authenticated-uri use the config below
1212

1313
/*restore_from_object_store {
14-
destination = "${var.destination[1]}"
15-
uri = "${data.oci_objectstorage_preauthrequest.vault_backup_preauthenticated_request}"
14+
destination = "${var.destination[1]}"
15+
uri = "${data.oci_objectstorage_preauthrequest.vault_backup_preauthenticated_request}"
16+
}*/
17+
18+
//If restoring using object in object storage use the config below
19+
20+
/*restore_from_file {
21+
restore_vault_from_file_details = "${data.oci_objectstorage_object.vault_backup_object.content}"
22+
content_length = "${data.oci_objectstorage_object.vault_backup_object.content_length}"
23+
24+
//Optional
25+
content_md5 = "${data.oci_objectstorage_object.vault_backup_object.content_md5}"
1626
}*/
1727

18-
compartment_id = "${var.compartment_id}"
19-
display_name = "${var.vault_display_name}"
20-
vault_type = "${var.vault_type[1]}"
21-
restore_trigger = "${var.vault_restore_trigger}"
28+
compartment_id = "${var.compartment_id}"
29+
30+
display_name = "${var.vault_display_name}"
31+
vault_type = "${var.vault_type[1]}"
32+
33+
//Flip the trigger when restore operation on vault needs to be performed
34+
//restore_trigger = "${var.vault_restore_trigger}"
2235
}

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ require (
77
github.com/hashicorp/hcl2 v0.0.0-20190618163856-0b64543c968c
88
github.com/hashicorp/terraform v0.12.4-0.20190628193153-a74738cd35fc
99
github.com/mitchellh/cli v1.0.0
10-
github.com/oracle/oci-go-sdk v20.0.0+incompatible
10+
github.com/oracle/oci-go-sdk v20.1.0+incompatible
1111
github.com/stretchr/objx v0.1.1 // indirect
1212
github.com/stretchr/testify v1.3.0
1313
gopkg.in/yaml.v2 v2.2.2

go.sum

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -451,6 +451,8 @@ github.com/oracle/oci-go-sdk v19.4.0+incompatible h1:9C9TQzYDbylb/dlDLwr9CL3EWK9
451451
github.com/oracle/oci-go-sdk v19.4.0+incompatible/go.mod h1:VQb79nF8Z2cwLkLS35ukwStZIg5F66tcBccjip/j888=
452452
github.com/oracle/oci-go-sdk v20.0.0+incompatible h1:PdKuaDT0DKwG7YMDpwjqsogpLhXt4z7Uxdabssvaucc=
453453
github.com/oracle/oci-go-sdk v20.0.0+incompatible/go.mod h1:VQb79nF8Z2cwLkLS35ukwStZIg5F66tcBccjip/j888=
454+
github.com/oracle/oci-go-sdk v20.1.0+incompatible h1:griRQj1BxbX+Drx8mKcRfey98S8/j5JKImFL2kh+qXE=
455+
github.com/oracle/oci-go-sdk v20.1.0+incompatible/go.mod h1:VQb79nF8Z2cwLkLS35ukwStZIg5F66tcBccjip/j888=
454456
github.com/packer-community/winrmcp v0.0.0-20180102160824-81144009af58 h1:m3CEgv3ah1Rhy82L+c0QG/U3VyY1UsvsIdkh0/rU97Y=
455457
github.com/packer-community/winrmcp v0.0.0-20180102160824-81144009af58/go.mod h1:f6Izs6JvFTdnRbziASagjZ2vmf55NSIkC/weStxCHqk=
456458
github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c h1:Lgl0gzECD8GnQ5QCWA8o6BtfL6mDH5rQgM4/fX3avOs=

oci/autoscaling_auto_scaling_configuration_data_source.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,14 @@ func (s *AutoScalingAutoScalingConfigurationDataSourceCrud) SetData() error {
9999
s.D.Set("is_enabled", *s.Res.IsEnabled)
100100
}
101101

102+
if s.Res.MaxResourceCount != nil {
103+
s.D.Set("max_resource_count", *s.Res.MaxResourceCount)
104+
}
105+
106+
if s.Res.MinResourceCount != nil {
107+
s.D.Set("min_resource_count", *s.Res.MinResourceCount)
108+
}
109+
102110
policies := []interface{}{}
103111
for _, item := range s.Res.Policies {
104112
policies = append(policies, AutoScalingPolicyToMap(item, true))

0 commit comments

Comments
 (0)