update
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1,2 +1,3 @@
|
|||||||
.terraform*
|
.terraform*
|
||||||
.env
|
.env
|
||||||
|
*.tfstate*
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
terraform {
|
terraform {
|
||||||
backend "http" {}
|
#backend "http" {}
|
||||||
required_providers {
|
required_providers {
|
||||||
gitlab = {
|
gitlab = {
|
||||||
source = "gitlabhq/gitlab"
|
source = "gitlabhq/gitlab"
|
||||||
@@ -41,11 +41,13 @@ resource "gitlab_branch_protection" "release" {
|
|||||||
}
|
}
|
||||||
|
|
||||||
resource "gitlab_project_runner_enablement" "k3s" {
|
resource "gitlab_project_runner_enablement" "k3s" {
|
||||||
|
count = var.GITLAB_SHARED_RUNNER_ID != 0 ? 1 : 0
|
||||||
project = gitlab_project.project.id
|
project = gitlab_project.project.id
|
||||||
runner_id = var.GITLAB_SHARED_RUNNER_ID
|
runner_id = var.GITLAB_SHARED_RUNNER_ID
|
||||||
}
|
}
|
||||||
|
|
||||||
resource "gitlab_project_variable" "OCTOAPI" {
|
resource "gitlab_project_variable" "OCTOAPI" {
|
||||||
|
count = var.OCTOAPI != "" ? 1 : 0
|
||||||
project = gitlab_project.project.id
|
project = gitlab_project.project.id
|
||||||
key = "OCTOAPI"
|
key = "OCTOAPI"
|
||||||
value = var.OCTOAPI
|
value = var.OCTOAPI
|
||||||
|
|||||||
@@ -2,18 +2,17 @@ variable "GITLAB_TOKEN" {
|
|||||||
type = string
|
type = string
|
||||||
}
|
}
|
||||||
|
|
||||||
variable "GITLAB_PROJECT_ID" {
|
|
||||||
type = number
|
|
||||||
}
|
|
||||||
|
|
||||||
variable "GITLAB_PROJECT_NAME" {
|
variable "GITLAB_PROJECT_NAME" {
|
||||||
type = string
|
type = string
|
||||||
}
|
}
|
||||||
|
|
||||||
variable "GITLAB_SHARED_RUNNER_ID" {
|
variable "GITLAB_SHARED_RUNNER_ID" {
|
||||||
type = number
|
type = number
|
||||||
|
default = 0
|
||||||
}
|
}
|
||||||
|
|
||||||
variable "OCTOAPI" {
|
variable "OCTOAPI" {
|
||||||
type = string
|
type = string
|
||||||
|
default = ""
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
13
TERRAFORM.OCTOPUS.PROJECTS/main.tf
Normal file
13
TERRAFORM.OCTOPUS.PROJECTS/main.tf
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
terraform {
|
||||||
|
required_providers {
|
||||||
|
octopusdeploy = {
|
||||||
|
source = "OctopusDeployLabs/octopusdeploy"
|
||||||
|
version = "0.13.3"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
provider "octopusdeploy" {
|
||||||
|
# Configuration options
|
||||||
|
}
|
||||||
|
|
||||||
Reference in New Issue
Block a user