This commit is contained in:
2023-12-19 08:14:10 -06:00
parent 9c52840bc5
commit b3f21b6113
3 changed files with 16 additions and 9 deletions

View File

@@ -35,11 +35,12 @@ resource "gitlab_project_runner_enablement" "k3s" {
runner_id = octopusdeploy_tenant_common_variable.gitlabrunnerid.value runner_id = octopusdeploy_tenant_common_variable.gitlabrunnerid.value
} }
#resource "gitlab_project_variable" "OCTOAPI" {
# count = var.OCTOAPI != "" ? 1 : 0 resource "gitlab_project_variable" "OCTOAPI" {
# project = gitlab_project.project.id count = var.Enable_OCTOAPI ? 1 : 0
# key = "OCTOAPI" project = gitlab_project.project.id
# value = var.OCTOAPI key = "OCTOAPI"
# protected = false value = var.OCTOAPI
# masked = true protected = false
#} masked = true
}

View File

@@ -11,6 +11,11 @@ variable "GITLAB_SHARED_RUNNER_ID" {
default = 0 default = 0
} }
variable "Enable_OCTOAPI" {
type = bool
default = false
}
variable "OCTOAPI" { variable "OCTOAPI" {
type = string type = string
default = "" default = ""

View File

@@ -2,5 +2,6 @@ GITLAB_TOKEN="#{GITLAB_TOKEN}"
GITLAB_PROJECT_NAME="#{GITLAB_PROJECT_NAME}" GITLAB_PROJECT_NAME="#{GITLAB_PROJECT_NAME}"
GITLAB_SHARED_RUNNER_ID="#{GITLAB_SHARED_RUNNER_ID}" GITLAB_SHARED_RUNNER_ID="#{GITLAB_SHARED_RUNNER_ID}"
OCTOAPI="#{OCTOAPI}" OCTOAPI="#{OCTOAPI}"
Enable_OCTOAPI="#{Enable_OCTOAPI}"
OCTO_TENANT_ID="#{OCTO_TENANT_ID}" OCTO_TENANT_ID="#{OCTO_TENANT_ID}"
Development="#{Development}" Development="#{Development}"