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

feat(cce node): Add runtime parameter #21

Merged
merged 1 commit into from
Dec 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,9 @@ module "cce2_cluster" {
network_id = "<NETWORK_ID>" //Caution here, you have to use NETWORK_ID even if argument is "subnet_id". Will be fixed soon
cluster_version = "v1.15.6-r1"

node_os = "CentOS 7.5" // Can be "EulerOS 2.5" or "CentOS 7.5"
key_pair = "my-key"
node_os = "CentOS 7.5" // Can be "EulerOS 2.5" or "CentOS 7.5"
node_runtime = "containerd // Valid values are docker and containerd"
key_pair = "my-key"

nodes_list = [
{
Expand Down Expand Up @@ -149,6 +150,7 @@ inputs = {
cluster_flavor = "cce.s1.small"
cluster_version = "v1.15.6-r1"
node_os = "CentOS 7.5" // Can be "EulerOS 2.5" or "CentOS 7.5"
node_runtime = "containerd // Valid values are docker and containerd"
key_pair = "my-key"

nodes_list = [
Expand Down
2 changes: 2 additions & 0 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ resource "flexibleengine_cce_node_v3" "cce_cluster_node" {
name = each.value.node_name
flavor_id = each.value.node_flavor
os = var.node_os
runtime = var.node_runtime

availability_zone = each.value.availability_zone
key_pair = var.key_pair
Expand Down Expand Up @@ -69,6 +70,7 @@ resource "flexibleengine_cce_node_pool_v3" "cce_node_pool" {
cluster_id = flexibleengine_cce_cluster_v3.cce_cluster.id
name = each.value.node_pool_name
os = var.node_os
runtime = var.node_runtime

flavor_id = each.value.node_flavor
availability_zone = each.value.availability_zone
Expand Down
6 changes: 6 additions & 0 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,12 @@ variable "node_os" {
type = string
}

variable "node_runtime" {
description = "Runtime of the CCE Worker Node. Valid values are docker and containerd."
type = string
default = "containerd"
}

variable "key_pair" {
description = "Name of the SSH key pair"
type = string
Expand Down