Skip to content

Commit b021895

Browse files
authored
Merge pull request #5 from oracle-community/aws-odb-4
Aws odb 4
2 parents 6acec0d + 1917007 commit b021895

9 files changed

+408
-181
lines changed
Lines changed: 48 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,55 @@
11
//Copyright © 2025, Oracle and/or its affiliates. All rights reserved.
22

3-
//Autonomous VM Cluster with default maintenance window
3+
//Autonomous VM Cluster with default maintenance window and minimum parameters
4+
resource "aws_odb_cloud_autonomous_vm_cluster" "avmc_with_minimum_parameters" {
5+
cloud_exadata_infrastructure_id = "<exadata_infra_id>" //refer your exadata infra id
6+
odb_network_id = "<odb_net_id>" //refer_your_odb_net_id
7+
display_name = "Ofake-avmc-my_avmc"
8+
autonomous_data_storage_size_in_tbs = 5
9+
memory_per_oracle_compute_unit_in_gbs = 2
10+
total_container_databases = 1
11+
cpu_core_count_per_node = 40
12+
license_model = "LICENSE_INCLUDED"
13+
//ids of db server. refer your exa infra. This is a manadatory fileld. Refer your cloud exadata infrastructure for db server id
14+
db_servers = ["<my_db_server_id>"]
15+
scan_listener_port_tls = 8561
16+
scan_listener_port_non_tls = 1024
17+
maintenance_window = {
18+
preference = "NO_PREFERENCE"
19+
days_of_week = []
20+
hours_of_day = []
21+
months = []
22+
weeks_of_month = []
23+
lead_time_in_weeks = 0
24+
}
25+
26+
}
27+
28+
//Autonomous VM Cluster with all parameters
429
resource "aws_odb_cloud_autonomous_vm_cluster" "test" {
5-
cloud_exadata_infrastructure_id = "<exadata_infra_id>" //refer your exadata infra id
6-
odb_network_id = "<odb_net_id>" //refer_your_odb_net_id
7-
display_name = "Ofake-avmc-my_avmc"
8-
autonomous_data_storage_size_in_tbs = 5
9-
memory_per_oracle_compute_unit_in_gbs = 2
10-
total_container_databases = 1
11-
cpu_core_count_per_node = 40
12-
license_model = "LICENSE_INCLUDED"
13-
db_servers = [] //ids of db server. refer your exa infra
14-
scan_listener_port_tls = 8561
15-
scan_listener_port_non_tls = 1024
30+
description = "my first avmc"
31+
time_zone = "UTC"
32+
cloud_exadata_infrastructure_id = "<aws_odb_cloud_exadata_infrastructure.test.id>"
33+
odb_network_id = "<aws_odb_network.test.id>"
34+
display_name = "Ofake_my avmc"
35+
autonomous_data_storage_size_in_tbs = 5
36+
memory_per_oracle_compute_unit_in_gbs = 2
37+
total_container_databases = 1
38+
cpu_core_count_per_node = 40
39+
license_model = "LICENSE_INCLUDED"
40+
db_servers = ["<my_db_server_1>", "<my_db_server_2>"]
41+
scan_listener_port_tls = 8561
42+
scan_listener_port_non_tls = 1024
1643
maintenance_window = {
17-
preference = "NO_PREFERENCE"
18-
days_of_week = []
19-
hours_of_day = []
20-
months = []
21-
weeks_of_month =[]
22-
lead_time_in_weeks = 0
44+
preference = "CUSTOM_PREFERENCE"
45+
days_of_week = ["MONDAY", "TUESDAY"]
46+
hours_of_day = [4, 16]
47+
months = ["FEBRUARY", "MAY", "AUGUST", "NOVEMBER"]
48+
weeks_of_month = [2, 4]
49+
lead_time_in_weeks = 3
50+
}
51+
tags = {
52+
"env" = "dev"
2353
}
2454

2555
}

examples/odb/exadata_infra.tf

Lines changed: 37 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,48 @@
11
//Copyright © 2025, Oracle and/or its affiliates. All rights reserved.
22

33
//Exadata Infrastructure with customer managed maintenance window
4-
resource "aws_odb_cloud_exadata_infrastructure" "test" {
5-
display_name = "Ofake_odb_exadata_infra" //Required Field
6-
shape = "Exadata.X11M" //Required Field
7-
storage_count = 3
8-
compute_count = 2
9-
availability_zone_id = "use1-az6" //Required Field
10-
customer_contacts_to_send_to_oci = ["[email protected]"]
11-
database_server_type = "X11M"
12-
storage_server_type = "X11M-HC"
4+
resource "aws_odb_cloud_exadata_infrastructure" "exa_infra_X11M_all_param" {
5+
display_name = "Ofake_my_odb_exadata_infra" //Required Field
6+
shape = "Exadata.X11M" //Required Field
7+
storage_count = 3
8+
compute_count = 2
9+
availability_zone_id = "use1-az6" //Required Field
10+
customer_contacts_to_send_to_oci = ["[email protected]"]
11+
database_server_type = "X11M"
12+
storage_server_type = "X11M-HC"
1313
maintenance_window = { //Required
14-
custom_action_timeout_in_mins = 16
15-
days_of_week = ["MONDAY", "TUESDAY"]
16-
hours_of_day = [11, 16]
17-
is_custom_action_timeout_enabled = true
18-
lead_time_in_weeks = 3
19-
months = ["FEBRUARY", "MAY", "AUGUST", "NOVEMBER"]
20-
patching_mode = "ROLLING"
21-
preference = "CUSTOM_PREFERENCE"
22-
weeks_of_month = [2, 4]
14+
custom_action_timeout_in_mins = 16
15+
days_of_week = ["MONDAY", "TUESDAY"]
16+
hours_of_day = [11, 16]
17+
is_custom_action_timeout_enabled = true
18+
lead_time_in_weeks = 3
19+
months = ["FEBRUARY", "MAY", "AUGUST", "NOVEMBER"]
20+
patching_mode = "ROLLING"
21+
preference = "CUSTOM_PREFERENCE"
22+
weeks_of_month = [2, 4]
2323
}
2424
tags = {
2525
"env" = "dev"
2626
}
2727

2828
}
2929

30-
//Exadata Infrastructure with default maintenance window
30+
//Exadata Infrastructure with default maintenance window with X9M system shape. with minimum parameters
31+
resource "aws_odb_cloud_exadata_infrastructure" "test_X9M" {
32+
display_name = "Ofake_my_exa_X9M"
33+
shape = "Exadata.X9M"
34+
storage_count = 3
35+
compute_count = 2
36+
availability_zone_id = "use1-az6"
37+
maintenance_window = {
38+
custom_action_timeout_in_mins = 16
39+
days_of_week = []
40+
hours_of_day = []
41+
is_custom_action_timeout_enabled = true
42+
lead_time_in_weeks = 0
43+
months = []
44+
patching_mode = "ROLLING"
45+
preference = "NO_PREFERENCE"
46+
weeks_of_month = []
47+
}
48+
}

examples/odb/odb_network_peering.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@
22

33
resource "aws_odb_network_peering_connection" "test" {
44
display_name = "my_odb_net_peering"
5-
odb_network_id = aws_odb_network.test.id
6-
peer_network_id = "vpc_id"
5+
odb_network_id = "<aws_odb_network.test.id">
6+
peer_network_id = "<vpc_id>"
77
}

examples/odb/vm_cluster.tf

Lines changed: 35 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,51 @@
11
//Copyright © 2025, Oracle and/or its affiliates. All rights reserved.
22

3-
resource "aws_odb_cloud_vm_cluster" "vmcluster" {
3+
resource "aws_odb_cloud_vm_cluster" "my_vmcluster_with_minimum_parameters" {
44
display_name = "Ofake_my_vmc"
5-
cloud_exadata_infrastructure_id = aws_odb_cloud_exadata_infrastructure.test.id
5+
cloud_exadata_infrastructure_id = "<aws_odb_cloud_exadata_infrastructure.test.id>"
66
cpu_core_count = 6
77
gi_version = "23.0.0.0"
88
hostname_prefix = "apollo12"
9-
ssh_public_keys = [""] //public ssh keys
10-
odb_network_id = aws_odb_network.test.id
9+
ssh_public_keys = [""] //public ssh keys
10+
odb_network_id = "<aws_odb_network.test.id>"
1111
is_local_backup_enabled = true
1212
is_sparse_diskgroup_enabled = true
1313
license_model = "LICENSE_INCLUDED"
1414
data_storage_size_in_tbs = 20.0
15-
db_servers = [""] //db-servers
15+
db_servers = ["<my_deb_server>"] //db-servers
1616
db_node_storage_size_in_gbs = 120.0
1717
memory_size_in_gbs = 60
1818
tags = {
1919
"env" = "dev"
2020
}
21+
}
22+
23+
24+
resource "aws_odb_cloud_vm_cluster" "my_vmc_with_all_parameters" {
25+
display_name = "Ofake_my_vmc"
26+
cloud_exadata_infrastructure_id = "<aws_odb_cloud_exadata_infrastructure.test.id>"
27+
cpu_core_count = 6
28+
gi_version = "23.0.0.0"
29+
hostname_prefix = "apollo12"
30+
ssh_public_keys = ["<my_ssh_public_key>"]
31+
odb_network_id = "<aws_odb_network.test.id>"
32+
is_local_backup_enabled = true
33+
is_sparse_diskgroup_enabled = true
34+
license_model = "LICENSE_INCLUDED"
35+
data_storage_size_in_tbs = 20.0
36+
db_servers = ["<my_db_server>"]
37+
db_node_storage_size_in_gbs = 120.0
38+
memory_size_in_gbs = 60
39+
cluster_name = "julia-13"
40+
timezone = "UTC"
41+
scan_listener_port_tcp = 1521
42+
system_version = "23.1.26.0.0.250516"
43+
tags = {
44+
"env" = "dev"
45+
}
46+
data_collection_options = {
47+
is_diagnostics_events_enabled = true
48+
is_health_monitoring_enabled = true
49+
is_incident_logs_enabled = true
50+
}
2151
}

0 commit comments

Comments
 (0)