Skip to content

Commit d7ef0b1

Browse files
committed
Update examples, worker pool resource names
Signed-off-by: Devon Crouse <[email protected]>
1 parent 7ee5777 commit d7ef0b1

28 files changed

+77
-81
lines changed

locals.tf

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,22 +2,16 @@
22
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl
33

44
locals {
5-
worker_image_id = (length(var.worker_pool_image_id) > 0 ? var.worker_pool_image_id
6-
: var.node_pool_image_id != "none" ? var.node_pool_image_id : "")
7-
worker_image_type = (length(var.worker_pool_image_type) > 0 ? var.worker_pool_image_type
8-
: var.node_pool_image_type != "none" ? var.node_pool_image_type : "")
9-
105
bastion_public_ip = var.create_bastion_host == true ? module.bastion[0].bastion_public_ip : var.bastion_public_ip != "" ? var.bastion_public_ip : ""
116
operator_private_ip = var.create_operator == true ? module.operator[0].operator_private_ip : var.operator_private_ip != "" ? var.operator_private_ip : ""
12-
operator_instance_principal_group_name = var.create_operator == true ? module.operator[0].operator_instance_principal_group_name : ""
13-
14-
vcn_id = var.create_vcn == true ? module.vcn[0].vcn_id : coalesce(var.vcn_id, try(data.oci_core_vcns.vcns[0].virtual_networks[0].id, ""))
15-
ig_route_id = var.create_vcn == true ? module.vcn[0].ig_route_id : coalesce(var.ig_route_table_id, try(data.oci_core_route_tables.ig[0].route_tables[0].id, ""))
16-
nat_route_id = var.create_vcn == true ? module.vcn[0].nat_route_id : coalesce(var.nat_route_table_id, try(data.oci_core_route_tables.nat[0].route_tables[0].id, ""))
7+
operator_instance_principal_group_name = var.create_operator && var.enable_operator_instance_principal ? module.operator[0].operator_instance_principal_group_name : ""
178

9+
ig_route_id = var.create_vcn == true ? module.vcn[0].ig_route_id : coalesce(var.ig_route_table_id, try(data.oci_core_route_tables.ig[0].route_tables[0].id, ""))
10+
nat_route_id = var.create_vcn == true ? module.vcn[0].nat_route_id : coalesce(var.nat_route_table_id, try(data.oci_core_route_tables.nat[0].route_tables[0].id, ""))
11+
vcn_id = var.create_vcn == true ? module.vcn[0].vcn_id : coalesce(var.vcn_id, try(data.oci_core_vcns.vcns[0].virtual_networks[0].id, ""))
1812
validate_drg_input = var.create_drg && (var.drg_id != null) ? tobool("[ERROR]: create_drg variable can not be true if drg_id is provided.]") : true
1913

20-
worker_pool_subnet_id = coalesce(
21-
var.worker_pool_subnet_id,
22-
lookup(module.network.subnet_ids, "workers", ""))
14+
worker_pool_subnet_id = coalesce(var.worker_pool_subnet_id, lookup(module.network.subnet_ids, "workers", ""))
15+
worker_image_id = length(var.worker_pool_image_id) > 0 ? var.worker_pool_image_id : var.node_pool_image_id != "none" ? var.node_pool_image_id : ""
16+
worker_image_type = length(var.worker_pool_image_type) > 0 ? var.worker_pool_image_type : var.node_pool_image_type != "none" ? var.node_pool_image_type : ""
2317
}

main.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2017, 2022 Oracle Corporation and/or affiliates.
1+
# Copyright (c) 2017, 2023 Oracle Corporation and/or its affiliates.
22
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl
33

44
module "vcn" {

modules/bastionsvc/variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2017, 2021 Oracle Corporation and/or affiliates.
1+
# Copyright (c) 2017, 2023 Oracle Corporation and/or its affiliates.
22
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl
33

44
# general oci

modules/extensions/activeworker.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2017, 2022 Oracle Corporation and/or affiliates.
1+
# Copyright (c) 2017, 2023 Oracle Corporation and/or its affiliates.
22
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl
33

44
resource "null_resource" "check_worker_active" {

modules/extensions/k8stools.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2017, 2022 Oracle Corporation and/or affiliates.
1+
# Copyright (c) 2017, 2023 Oracle Corporation and/or its affiliates.
22
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl
33

44
resource "null_resource" "install_k8stools_on_operator" {

modules/extensions/kubeconfig.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2017, 2021 Oracle Corporation and/or affiliates.
1+
# Copyright (c) 2017, 2023 Oracle Corporation and/or its affiliates.
22
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl
33

44
resource "null_resource" "write_kubeconfig_on_operator" {

modules/extensions/locals.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2017, 2022 Oracle Corporation and/or affiliates.
1+
# Copyright (c) 2017, 2023 Oracle Corporation and/or its affiliates.
22
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl
33

44
locals {

modules/extensions/scripts/check_worker_active.template.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env bash
2-
# Copyright 2017, 2022 Oracle Corporation and/or affiliates.
2+
# Copyright (c) 2017, 2023 Oracle Corporation and/or its affiliates.
33
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl
44
# shellcheck disable=SC1083,SC2309,SC2154,SC2157,SC2034 # Ignore templated/escaped/unused file variables
55
export ALL_FILE=~/all_node.active ONE_FILE=~/one_node.active

modules/extensions/templates.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright (c) 2017, 2022 Oracle Corporation and/or its affiliates.
1+
# Copyright (c) 2017, 2023 Oracle Corporation and/or its affiliates.
22
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl
33

44
locals {

modules/extensions/variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright 2017, 2019 Oracle Corporation and/or affiliates.
1+
# Copyright (c) 2017, 2023 Oracle Corporation and/or its affiliates.
22
# Licensed under the Universal Permissive License v 1.0 as shown at https://oss.oracle.com/licenses/upl
33

44
# oci provider

0 commit comments

Comments
 (0)