diff --git a/.github/workflows/maintenance.yml b/.github/workflows/maintenance.yml index d7ec75d361..76196892da 100644 --- a/.github/workflows/maintenance.yml +++ b/.github/workflows/maintenance.yml @@ -1,6 +1,8 @@ name: Set maintenance mode on: + push: + branches: [add-maintenance-page] workflow_dispatch: inputs: environment: @@ -20,7 +22,7 @@ jobs: set-maintenance-mode: name: Set maintenance mode runs-on: ubuntu-latest - environment: ${{ inputs.environment }} + environment: review steps: - name: Checkout @@ -30,7 +32,7 @@ jobs: uses: DFE-Digital/github-actions/maintenance@master with: azure-credentials: ${{ secrets.AZURE_CREDENTIALS}} - environment: ${{ inputs.environment }} - mode: ${{ inputs.mode }} + environment: review + mode: enable docker-repository: ghcr.io/dfe-digital/claim-additional-payments-for-teaching-maintenance github-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/Makefile b/Makefile index 938d77d096..9ef0514fb7 100644 --- a/Makefile +++ b/Makefile @@ -11,7 +11,7 @@ help: .PHONY: review review: test-cluster - $(if ${PR_NUMBER},,$(error Missing PR_NUMBER)) + $(eval export PR_NUMBER=3419) $(eval ENVIRONMENT=review-${PR_NUMBER}) $(eval export TF_VAR_environment=${ENVIRONMENT}) $(eval include global_config/review.sh) diff --git a/maintenance_page/manifests/review/ingress_internal_to_main.yml b/maintenance_page/manifests/review/ingress_internal_to_main.yml new file mode 100644 index 0000000000..f31e1c2e75 --- /dev/null +++ b/maintenance_page/manifests/review/ingress_internal_to_main.yml @@ -0,0 +1,16 @@ +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: claim-additional-payments-for-teaching-review-3419-web.test.teacherservices.cloud +spec: + ingressClassName: nginx + rules: + - host: claim-additional-payments-for-teaching-review-3419-web.test.teacherservices.cloud + http: + paths: + - pathType: ImplementationSpecific + backend: + service: + name: claim-additional-payments-for-teaching-review-3419-web + port: + number: 80 diff --git a/maintenance_page/manifests/review/ingress_internal_to_maintenance.yml b/maintenance_page/manifests/review/ingress_internal_to_maintenance.yml new file mode 100644 index 0000000000..66dfb16e65 --- /dev/null +++ b/maintenance_page/manifests/review/ingress_internal_to_maintenance.yml @@ -0,0 +1,16 @@ +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: claim-additional-payments-for-teaching-review-3419-web.test.teacherservices.cloud +spec: + ingressClassName: nginx + rules: + - host: claim-additional-payments-for-teaching-review-3419-web.test.teacherservices.cloud + http: + paths: + - pathType: ImplementationSpecific + backend: + service: + name: claim-additional-payments-for-teaching-maintenance + port: + number: 80 diff --git a/maintenance_page/manifests/review/ingress_maintenance.yml b/maintenance_page/manifests/review/ingress_maintenance.yml new file mode 100644 index 0000000000..db8d01c1e2 --- /dev/null +++ b/maintenance_page/manifests/review/ingress_maintenance.yml @@ -0,0 +1,16 @@ +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: claim-additional-payments-for-teaching-maintenance.test.teacherservices.cloud +spec: + ingressClassName: nginx + rules: + - host: claim-additional-payments-for-teaching-maintenance.test.teacherservices.cloud + http: + paths: + - pathType: ImplementationSpecific + backend: + service: + name: claim-additional-payments-for-teaching-maintenance + port: + number: 80 diff --git a/maintenance_page/manifests/review/ingress_temp_to_main.yml b/maintenance_page/manifests/review/ingress_temp_to_main.yml new file mode 100644 index 0000000000..bc3b068ca5 --- /dev/null +++ b/maintenance_page/manifests/review/ingress_temp_to_main.yml @@ -0,0 +1,16 @@ +apiVersion: networking.k8s.io/v1 +kind: Ingress +metadata: + name: claim-additional-payments-for-teaching-temp.test.teacherservices.cloud +spec: + ingressClassName: nginx + rules: + - host: claim-additional-payments-for-teaching-temp.test.teacherservices.cloud + http: + paths: + - pathType: ImplementationSpecific + backend: + service: + name: claim-additional-payments-for-teaching-review-3419-web + port: + number: 80