Skip to content

Commit 32244a8

Browse files
authored
Tested with ARM (#31)
* tested with ARM, changed default shape to E4.Flex, added ability to control state of operator host * added deprecation notice in changelog * Update variables.tf Changed default shape in variables to E4
1 parent 276bf12 commit 32244a8

File tree

5 files changed

+43
-12
lines changed

5 files changed

+43
-12
lines changed

CHANGELOG.adoc

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,20 @@ All notable changes to this project are documented in this file.
77

88
The format is based on {uri-changelog}[Keep a Changelog].
99

10+
= Unreleased
11+
12+
== New features
13+
* New variable (`operator_state`) to specify state of operator host
14+
15+
== Changes
16+
* Set default shape to E4.Flex
17+
18+
== Deprecation notice
19+
20+
The following variables will be renamed at the next major release of this module:
21+
22+
* var.operator_enabled --> var.create_operator
23+
1024
== v2.1.0 (March 22,2021)
1125
* Upgrade default version of operator host to Oracle Linux 8 (#26)
1226

compute.tf

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,13 @@ resource "oci_core_instance" "operator" {
4646
}
4747
}
4848

49-
5049
source_details {
5150
source_type = "image"
5251
source_id = local.operator_image_id
5352
}
5453

54+
state = var.operator_state
55+
5556
timeouts {
5657
create = "60m"
5758
}

docs/terraformoptions.adoc

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -141,17 +141,23 @@ Ensure you review the {uri-terraform-dependencies}[dependencies].
141141
|`operator_shape`
142142
|The shape of operator instance. This is now specified as a map and supports E3.Flex. If a non-Flex shape is specified, then the other parameters are ignored.
143143
|e.g. `operator_shape = {
144-
shape="VM.Standard.E3.Flex",
144+
shape="VM.Standard.E4.Flex",
145145
ocpus=1,
146146
memory=4,
147147
boot_volume_size=50
148148
}`
149149
|`operator_shape = {
150-
shape="VM.Standard.E3.Flex",
150+
shape="VM.Standard.E4.Flex",
151151
ocpus=1,
152152
memory=4,
153153
boot_volume_size=50
154154
}`
155+
156+
|`operator_state`
157+
|The target state for the instance. Could be set to RUNNING or STOPPED. (Updatable)
158+
|RUNNING|STOPPED
159+
|RUNNING
160+
155161
|`operator_upgrade`
156162
|Whether to upgrade the operator host packages after provisioning. It's useful to set this to false during development/testing so the operator is provisioned faster.
157163
|true/false

terraform.tfvars.example

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,8 @@ nsg_ids = []
3333

3434
vcn_id = ""
3535

36+
operating_system_version = "8"
37+
3638
operator_enabled = true
3739

3840
operator_image_id = "Oracle"
@@ -41,13 +43,13 @@ operator_instance_principal = true
4143

4244
operator_shape = {
4345
# shape = "VM.Standard.E2.2"
44-
shape="VM.Standard.E3.Flex",
46+
shape="VM.Standard.E4.Flex",
4547
ocpus=1,
4648
memory=4,
4749
boot_volume_size=50
4850
}
4951

50-
operating_system_version = "8"
52+
operator_state= "RUNNING"
5153

5254
operator_upgrade = false
5355

variables.tf

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -83,14 +83,21 @@ variable "vcn_id" {
8383

8484
# operator host parameters
8585

86+
variable "operating_system_version" {
87+
description = "The version of the Oracle Linux to use."
88+
default = "8"
89+
type = string
90+
}
91+
8692
variable "operator_enabled" {
93+
#! Deprecation notice: will be renamed to create_operator at next major release
8794
description = "whether to create the operator"
8895
default = false
8996
type = bool
9097
}
9198

9299
variable "operator_image_id" {
93-
description = "Provide a custom image id for the operator host or leave as Autonomous."
100+
description = "Provide a custom image id for the operator host or leave as Oracle."
94101
default = "Oracle"
95102
type = string
96103
}
@@ -103,17 +110,18 @@ variable "operator_instance_principal" {
103110

104111
variable "operator_shape" {
105112
description = "The shape of the operator instance."
106-
default = {
107-
shape = "VM.Standard.E3.Flex", ocpus = 1, memory = 4, boot_volume_size = 50
113+
default = {
114+
shape = "VM.Standard.E4.Flex", ocpus = 1, memory = 4, boot_volume_size = 50
108115
}
109-
type = map(any)
116+
type = map(any)
110117
}
111118

112-
variable "operating_system_version" {
113-
description = "The version of the Oracle Linux to use."
114-
default = "8"
119+
variable "operator_state" {
120+
description = "The target state for the instance. Could be set to RUNNING or STOPPED. (Updatable)"
121+
default = "RUNNING"
115122
type = string
116123
}
124+
117125
variable "operator_upgrade" {
118126
description = "Whether to upgrade the operator host packages after provisioning. It's useful to set this to false during development/testing so the operator is provisioned faster."
119127
default = false

0 commit comments

Comments
 (0)