File tree Expand file tree Collapse file tree 2 files changed +3
-17
lines changed
Expand file tree Collapse file tree 2 files changed +3
-17
lines changed Original file line number Diff line number Diff line change 99
1010 final_namespace = var. create_namespace ? resource. kubernetes_namespace_v1 . this [0 ]. metadata [0 ]. name : data. kubernetes_namespace_v1 . this [0 ]. metadata [0 ]. name
1111
12+ use_existing_project = var. gitlab_project_name == " " ? 1 : 0
13+ project_id = local. use_existing_project == 1 ? data. gitlab_project . this [0 ]. id : gitlab_project. project [0 ]. id
14+
1215 gitlab_agent_token_name_computed = replace (var. gitlab_agent_token_name , " {{gitlab_agent_name}}" , var. gitlab_agent_name )
1316 gitlab_agent_token_description_computed = replace (var. gitlab_agent_token_description , " {{gitlab_agent_name}}" , var. gitlab_agent_name )
1417 gitlab_agent_commmit_message_computed = replace (var. gitlab_agent_commmit_message , " {{gitlab_agent_name}}" , var. gitlab_agent_name )
@@ -22,10 +25,6 @@ locals {
2225 (var. gitlab_agent_variable_name_agent_id ) : gitlab_cluster_agent.this.name,
2326 (var. gitlab_agent_variable_name_agent_project ) : local.use_existing_project == 1 ? data.gitlab_project.this[0 ].path_with_namespace : gitlab_project.project[0 ].path_with_namespace,
2427 }
25- use_existing_project = var. gitlab_project_name == " " ? 1 : 0
26- project_id = local. use_existing_project == 1 ? data. gitlab_project . this [0 ]. id : gitlab_project. project [0 ]. id
27-
28-
2928}
3029
3130# Gitlab resources
Original file line number Diff line number Diff line change @@ -4,19 +4,6 @@ variable "gitlab_project_name" {
44 default = " "
55}
66
7- variable "gitlab_project_details" {
8- description = " Details of the Gitlab project including name, group, and description"
9- type = object ({
10- name = string
11- group = string
12- })
13- default = {
14- name = " "
15- group = " "
16- description = " "
17- }
18- }
19-
207variable "gitlab_root_namespace" {
218 description = " The full path of the root namespace in Gitlab. This is the namespace where the Gitlab Agent will be granted access."
229 type = string
You can’t perform that action at this time.
0 commit comments