Skip to content

Commit

Permalink
feat: Support license as a secretKeyRef
Browse files Browse the repository at this point in the history
  • Loading branch information
amanpruthi committed Sep 17, 2024
1 parent b26294b commit 9f2029b
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 10 deletions.
18 changes: 11 additions & 7 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -162,10 +162,10 @@ module "redis" {
}

module "clickhouse" {
count = var.clickhouse_private_endpoint_service_name != "" ? 1 : 0
source = "./modules/clickhouse"
network = local.network.id
namespace = var.namespace
count = var.clickhouse_private_endpoint_service_name != "" ? 1 : 0
source = "./modules/clickhouse"
network = local.network.id
namespace = var.namespace

clickhouse_reserved_ip_range = var.clickhouse_subnetwork_cidr
clickhouse_private_endpoint_service_name = var.clickhouse_private_endpoint_service_name
Expand Down Expand Up @@ -254,9 +254,13 @@ module "wandb" {
spec = {
values = {
global = {
pod = { labels = { workload_hash : local.workload_hash } }
host = local.url
license = var.license
pod = { labels = { workload_hash : local.workload_hash } }
host = local.url
license = var.license
licenseSecret = {
name = var.license_secret_name, ## this will support wandb-operator chart version 0.17.9
key = var.license_secret_key_name
}
cloudProvider = "gcp"
extraEnv = merge({
"GORILLA_DISABLE_CODE_SAVING" = var.disable_code_saving,
Expand Down
18 changes: 15 additions & 3 deletions variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -205,9 +205,9 @@ variable "bucket_location" {
}

variable "skip_bucket_admin_role" {
type = bool
description = "Flag to indicate whether to skip the bucket policy creation."
default = false
type = bool
description = "Flag to indicate whether to skip the bucket policy creation."
default = false
}
##########################################
# Bucket Subpath #
Expand Down Expand Up @@ -379,3 +379,15 @@ variable "clickhouse_subnetwork_cidr" {
description = "ClickHouse private service connect subnetwork"
type = string
}

variable "license_secret_name" {
type = string
description = "Wandb licence secret name"
default = ""
}

variable "license_secret_key_name" {
type = string
description = "Wandb licence secret key name"
default = ""
}

0 comments on commit 9f2029b

Please sign in to comment.