Skip to content

Commit bb72474

Browse files
committed
updating naming conventions and all that
1 parent a2be076 commit bb72474

File tree

4 files changed

+14
-32
lines changed

4 files changed

+14
-32
lines changed

terraform/main.tf

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,6 @@ resource "azuredevops_build_definition" "this" {
4848

4949
variable_groups = [
5050
azuredevops_variable_group.infra_variable_group.id,
51-
azuredevops_variable_group.image_repo_variable.id,
5251
]
5352

5453
variable {

terraform/outputs.tf

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
output "acr_name" {
2+
value = azurerm_container_registry.this_container_registry.name
3+
}
4+
5+
output "acr_url" {
6+
value = azurerm_container_registry.this_container_registry.login_server
7+
}

terraform/variable-group.tf

Lines changed: 4 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -5,37 +5,13 @@ resource "azuredevops_variable_group" "infra_variable_group" {
55
allow_access = true
66

77
variable {
8-
name = "ACR_NAME"
9-
secret_value = azurerm_container_registry.this_container_registry.name
10-
is_secret = false
8+
name = "ACR_URL"
9+
value = azurerm_container_registry.this_container_registry.login_server
1110

1211
}
1312

1413
variable {
15-
name = "ACR_SERVICE_CONNECTION"
16-
secret_value = azuredevops_serviceendpoint_azurecr.acr_registry_endpoint.id
17-
is_secret = false
18-
}
19-
}
20-
21-
22-
resource "azuredevops_variable_group" "image_repo_variable" {
23-
project_id = azuredevops_project.this.id
24-
name = "Image Repository Variables"
25-
description = "Managed by Terraform"
26-
allow_access = true
27-
28-
variable {
29-
name = "imageRepository"
30-
value = ""
31-
}
32-
variable {
33-
name = "containerRegistry"
34-
value = ""
35-
}
36-
37-
variable {
38-
name = "AZ_CONTAINER_NAME"
39-
value = ""
14+
name = "ACR_SERVICE_CONNECTION"
15+
value = azuredevops_serviceendpoint_azurecr.acr_registry_endpoint.id
4016
}
4117
}

terraform/variables.tf

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,20 +26,20 @@ variable "location" {
2626
variable "acr_name" {
2727
type = string
2828
description = "name of the Azure Container Registry"
29-
default = "fastapidevsecopsacr"
29+
default = "DSB-Container-Registry"
3030

3131
}
3232

3333
variable "aks_name" {
3434
type = string
3535
description = "name of the Azure Kubernetes Service"
36-
default = "fastapidevsecopsaks"
36+
default = "DSB-AKS-Cluster"
3737

3838
}
3939

4040
variable "uaid_name" {
4141
type = string
4242
description = "name of the Azure Kubernetes Service"
43-
default = "DevSecOps-User-Assigned-Identity"
43+
default = "DSB-User-Assigned-Identity"
4444

4545
}

0 commit comments

Comments
 (0)