diff --git a/pkg/fixtures/workflows/azurepipelines/manifests/.pipelines/azure-kubernetes-service.yaml b/pkg/fixtures/workflows/azurepipelines/manifests/.pipelines/azure-kubernetes-service.yaml deleted file mode 100644 index c4fd7718..00000000 --- a/pkg/fixtures/workflows/azurepipelines/manifests/.pipelines/azure-kubernetes-service.yaml +++ /dev/null @@ -1,60 +0,0 @@ -# Azure Kubernetes Service pipeline -# Build and push image to Azure Container Registry; Deploy to Azure Kubernetes Service cluster - -variables: - armServiceConnection: testserviceconnection - azureContainerRegistry: myacr.acr.io - containerName: myapp - clusterRg: myrg - acrRg: myrg - clusterName: testcluster - manifestPath: ./manifests - namespace: default - tag: "$(Build.BuildId)" - vmImageName: "ubuntu-latest" - -name: Build and deploy an app to AKS - -trigger: - - main - -stages: - - stage: BuildAndPush - displayName: Build stage - jobs: - - job: BuildAndPush - displayName: Build and push image - pool: - vmImage: $(vmImageName) - steps: - - task: AzureCLI@2 - displayName: Build and push image to Azure Container Registry - inputs: - azureSubscription: $(armServiceConnection) - scriptType: "bash" - scriptLocation: "inlineScript" - inlineScript: | - az acr build --image $1.azurecr.io/$2:$3 --registry $1 -g $4 . - arguments: "$(azureContainerRegistry) $(containerName) $(tag) $(acrRg)" - - - stage: Deploy - displayName: Deploy stage - dependsOn: BuildAndPush - jobs: - - job: Deploy - displayName: Deploy to AKS - pool: - vmImage: $(vmImageName) - steps: - - task: KubernetesManifest@1 - displayName: Deploy to Kubernetes cluster - inputs: - action: "deploy" - connectionType: "azureResourceManager" - azureSubscriptionConnection: $(armServiceConnection) - azureResourceGroup: $(clusterRg) - kubernetesCluster: $(clusterName) - manifests: $(manifestPath) - namespace: $(namespace) - containers: | - $(azureContainerRegistry).azurecr.io/$(containerName):$(tag) diff --git a/template/azurePipelines/manifests/.pipelines/azure-kubernetes-service.yaml b/template/azurePipelines/manifests/.pipelines/azure-kubernetes-service.yaml deleted file mode 100644 index 1f963d1c..00000000 --- a/template/azurePipelines/manifests/.pipelines/azure-kubernetes-service.yaml +++ /dev/null @@ -1,61 +0,0 @@ -# Azure Kubernetes Service pipeline -# Build and push image to Azure Container Registry; Deploy to Azure Kubernetes Service cluster - -variables: - armServiceConnection: {{ .Config.GetVariableValue "ARMSERVICECONNECTION" }} - azureContainerRegistry: {{ .Config.GetVariableValue "AZURECONTAINERREGISTRY" }} - containerName: {{ .Config.GetVariableValue "CONTAINERNAME" }} - clusterRg: {{ .Config.GetVariableValue "CLUSTERRESOURCEGROUP" }} - acrRg: {{ .Config.GetVariableValue "ACRRESOURCEGROUP" }} - clusterName: {{ .Config.GetVariableValue "CLUSTERNAME" }} - manifestPath: {{ .Config.GetVariableValue "MANIFESTPATH" }} - namespace: {{ .Config.GetVariableValue "NAMESPACE" }} - tag: "$(Build.BuildId)" - vmImageName: "ubuntu-latest" - -name: {{ .Config.GetVariableValue "PIPELINENAME" }} - -trigger: - - {{ .Config.GetVariableValue "BRANCHNAME" }} -{{` -stages: - - stage: BuildAndPush - displayName: Build stage - jobs: - - job: BuildAndPush - displayName: Build and push image - pool: - vmImage: $(vmImageName) - steps: - - task: AzureCLI@2 - displayName: Build and push image to Azure Container Registry - inputs: - azureSubscription: $(armServiceConnection) - scriptType: "bash" - scriptLocation: "inlineScript" - inlineScript: | - az acr build --image $1.azurecr.io/$2:$3 --registry $1 -g $4 . - arguments: "$(azureContainerRegistry) $(containerName) $(tag) $(acrRg)" - - - stage: Deploy - displayName: Deploy stage - dependsOn: BuildAndPush - jobs: - - job: Deploy - displayName: Deploy to AKS - pool: - vmImage: $(vmImageName) - steps: - - task: KubernetesManifest@1 - displayName: Deploy to Kubernetes cluster - inputs: - action: "deploy" - connectionType: "azureResourceManager" - azureSubscriptionConnection: $(armServiceConnection) - azureResourceGroup: $(clusterRg) - kubernetesCluster: $(clusterName) - manifests: $(manifestPath) - namespace: $(namespace) - containers: | - $(azureContainerRegistry).azurecr.io/$(containerName):$(tag) -`}} \ No newline at end of file diff --git a/template/azurePipelines/manifests/draft.yaml b/template/azurePipelines/manifests/draft.yaml deleted file mode 100644 index 755c0e51..00000000 --- a/template/azurePipelines/manifests/draft.yaml +++ /dev/null @@ -1,65 +0,0 @@ -templateName: "azure-pipeline-manifest" -description: "Azure Pipeline for deploying a containerized application to AKS using kubernetes manifests" -versions: "0.0.1" -defaultVersion: "0.0.1" -type: "workflow" -variables: - - name: "PIPELINENAME" - type: "string" - kind: "workflowName" - default: - value: "Build and deploy an app to AKS" - description: "the name of the azure pipeline" - versions: ">=0.0.1" - - name: "BRANCHNAME" - type: "string" - kind: "repositoryBranch" - default: - value: "main" - description: "the branch to trigger the pipeline" - versions: ">=0.0.1" - - name: "ARMSERVICECONNECTION" - type: "string" - kind: "azureServiceConnection" - description: "the name of the Azure Resource Manager service connection" - versions: ">=0.0.1" - - name: "AZURECONTAINERREGISTRY" - type: "string" - kind: "azureContainerRegistry" - description: "the name of the Azure Container Registry" - versions: ">=0.0.1" - - name: "CONTAINERNAME" - type: "string" - kind: "containerImageName" - description: "the container image name" - versions: ">=0.0.1" - - name: "CLUSTERRESOURCEGROUP" - type: "string" - kind: "azureResourceGroup" - description: "the AKS cluster resource group" - versions: ">=0.0.1" - - name: "ACRRESOURCEGROUP" - type: "string" - kind: "azureResourceGroup" - description: "the ACR resource group" - versions: ">=0.0.1" - - name: "CLUSTERNAME" - type: "string" - kind: "azureManagedCluster" - description: "the AKS cluster name" - versions: ">=0.0.1" - - name: "MANIFESTPATH" - type: "string" - kind: "dirPath" - default: - disablePrompt: true - value: "./manifests" - description: "the path to the Kubernetes deployment manifest" - versions: ">=0.0.1" - - name: "NAMESPACE" - type: "string" - kind: "kubernetesNamespace" - default: - value: "default" - description: "the Kubernetes namespace" - versions: ">=0.0.1"