diff --git a/.github/workflows/execute-performance.yaml b/.github/workflows/execute-performance.yaml index ecec17e..4469e3b 100644 --- a/.github/workflows/execute-performance.yaml +++ b/.github/workflows/execute-performance.yaml @@ -32,6 +32,11 @@ jobs: - name: Get cluster context run: make get-cluster-context + - name: Scale cluster + run: make scale-node-pool + env: + NODE_POOL_SIZE: 3 + - name: Deploy dependencies run: make deploy @@ -43,3 +48,9 @@ jobs: - name: Cleanup dependencies run: make undeploy if: ${{ always() }} + + - name: Scale cluster + if: ${{ always() }} + run: make scale-node-pool + env: + NODE_POOL_SIZE: 1 diff --git a/Makefile b/Makefile index 22ccec9..a4a5bd5 100644 --- a/Makefile +++ b/Makefile @@ -23,6 +23,8 @@ REPO_URL ?= https://github.com/kedacore/keda-performance.git REPO_BRANCH ?= main TEST_CONFIG ?= config.json +NODE_POOL_SIZE ?= 1 + ################################################## # Kubernetes context # ################################################## @@ -36,6 +38,14 @@ get-cluster-context: az-login ## Get Azure cluster context. --subscription $(TF_AZURE_SUBSCRIPTION) \ --resource-group $(TF_AZURE_RESOURCE_GROUP) +.PHONY: scale-node-pool +scale-node-pool: az-login ## Scale nodepool. + @az aks scale \ + --name $(TEST_CLUSTER_NAME) \ + --subscription $(TF_AZURE_SUBSCRIPTION) \ + --resource-group $(TF_AZURE_RESOURCE_GROUP) \ + --node-count $(NODE_POOL_SIZE) + ################################################## # Deployments # ##################################################