Skip to content

Commit

Permalink
testing module changes
Browse files Browse the repository at this point in the history
  • Loading branch information
tonytheleg committed May 20, 2024
1 parent 42b7b19 commit 66e5016
Show file tree
Hide file tree
Showing 4 changed files with 66 additions and 34 deletions.
2 changes: 1 addition & 1 deletion dev-infrastructure/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ svc-cluster: setsubscription rg
az deployment group create \
--name "$(DEPLOYMENTNAME)" \
--resource-group $(RESOURCEGROUP) \
--template-file templates/svc-cluster.bicep \
--template-file templates/svc-cluster-deploy.bicep \
--confirm-with-what-if \
--parameters \
configurations/${AKSCONFIG}.bicepparam \
Expand Down
4 changes: 2 additions & 2 deletions dev-infrastructure/configurations/svc-cluster.bicepparam
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using '../templates/svc-cluster.bicep'
using '../templates/svc-cluster-deploy.bicep'

param kubernetesVersion = '1.29.2'
param istioVersion = 'asm-1-20'
Expand All @@ -8,7 +8,7 @@ param podSubnetPrefix = '10.128.64.0/18'
param enablePrivateCluster = false
param persist = false
param disableLocalAuth = false
param deployFrontendCosmos = false
param deployFrontendCosmos = true
param deployMaestroInfra = false
param maestroNamespace = 'maestro'
param workloadIdentities = items({
Expand Down
Original file line number Diff line number Diff line change
@@ -1,51 +1,21 @@
@description('Azure Region Location')
param location string = resourceGroup().location

@description('Set to true to prevent resources from being pruned after 48 hours')
param persist bool = false

@description('Captures logged in users UID')
param currentUserId string

@description('VNET address prefix')
param vnetAddressPrefix string

@description('Subnet address prefix')
param subnetPrefix string

@description('Specifies the address prefix of the subnet hosting the pods of the AKS cluster.')
param podSubnetPrefix string

@description('(Optional) boolean flag to configure public/private AKS Cluster')
param enablePrivateCluster bool

@description('Kuberentes version to use with AKS')
param kubernetesVersion string

@description('Istio control plane version to use with AKS')
param istioVersion string

// TODO: When the work around workload identity for the RP is finalized, change this to true
@description('disableLocalAuth for the ARO HCP RP CosmosDB')
param disableLocalAuth bool

@description('Deploy ARO HCP RP Azure Cosmos DB if true')
param deployFrontendCosmos bool

@description('List of workload identities to create and their required values')
param workloadIdentities array

@description('Deploy ARO HCP Maestro Infrastructure if true')
param deployMaestroInfra bool

@description('The namespace where the maestro resources will be deployed.')
param maestroNamespace string

@description('The OneCertV2 domain to use to use for the maestro certificate.')
param maestroCertDomain string?

module svcCluster '../modules/aks-cluster-base.bicep' = {
name: 'svc-cluster'
name: 'aks-svc-cluster'
scope: resourceGroup()
params: {
location: location
Expand Down
62 changes: 62 additions & 0 deletions dev-infrastructure/templates/svc-cluster-deploy.bicep
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
@description('Azure Region Location')
param location string = resourceGroup().location

@description('Set to true to prevent resources from being pruned after 48 hours')
param persist bool = false

@description('Captures logged in users UID')
param currentUserId string

@description('VNET address prefix')
param vnetAddressPrefix string

@description('Subnet address prefix')
param subnetPrefix string

@description('Specifies the address prefix of the subnet hosting the pods of the AKS cluster.')
param podSubnetPrefix string

@description('(Optional) boolean flag to configure public/private AKS Cluster')
param enablePrivateCluster bool

@description('Kuberentes version to use with AKS')
param kubernetesVersion string

@description('Istio control plane version to use with AKS')
param istioVersion string

// TODO: When the work around workload identity for the RP is finalized, change this to true
@description('disableLocalAuth for the ARO HCP RP CosmosDB')
param disableLocalAuth bool

@description('Deploy ARO HCP RP Azure Cosmos DB if true')
param deployFrontendCosmos bool

@description('List of workload identities to create and their required values')
param workloadIdentities array

@description('Deploy ARO HCP Maestro Infrastructure if true')
param deployMaestroInfra bool

@description('The namespace where the maestro resources will be deployed.')
param maestroNamespace string

module build_svc_cluster 'br:anataleacrtest.azurecr.io/bicep/modules/svc-cluster:v1' = {
name: 'hcp-services-cluster'
params: {
location: location
kubernetesVersion: kubernetesVersion
istioVersion: istioVersion
vnetAddressPrefix: vnetAddressPrefix
subnetPrefix: subnetPrefix
podSubnetPrefix: podSubnetPrefix
enablePrivateCluster: enablePrivateCluster
persist: persist
disableLocalAuth: disableLocalAuth
deployFrontendCosmos: deployFrontendCosmos
deployMaestroInfra: deployMaestroInfra
maestroNamespace: maestroNamespace
currentUserId: currentUserId
workloadIdentities: workloadIdentities
}
}

0 comments on commit 66e5016

Please sign in to comment.