From 322c880a6c59156f104d8777848b39fb5f7052f2 Mon Sep 17 00:00:00 2001 From: Andrew Hughes-Onslow Date: Tue, 23 Jul 2024 10:10:27 +0100 Subject: [PATCH] ATO-762: [deploy] Removing unecessary service. --- .../build-backend-component/action.yml | 47 ------------------- .github/workflows/deploy-branch.yml | 22 ++++----- 2 files changed, 11 insertions(+), 58 deletions(-) delete mode 100644 .github/actions/build-backend-component/action.yml diff --git a/.github/actions/build-backend-component/action.yml b/.github/actions/build-backend-component/action.yml deleted file mode 100644 index 58511ec0b..000000000 --- a/.github/actions/build-backend-component/action.yml +++ /dev/null @@ -1,47 +0,0 @@ -name: "Build application" -description: "Build and compile all the assets required to run the application in the container" -inputs: - component: - description: "The backend component to build" - required: true - artifact-name: - description: "The artifact name to store the build cache under" - required: true - default: backend-build -outputs: - artifact-id: - description: "The artifact id for the artifact that was just uploaded or empty if the artifact upload failed." - value: ${{ steps.upload.outputs.artifact-id }} -runs: - using: composite - steps: - - name: Pull repository - id: checkout - uses: actions/checkout@v4 - - - name: Install Node - id: node - uses: actions/setup-node@v4 - with: - cache: npm - node-version: 18 - - - name: Install Node dependencies - id: install - shell: bash - working-directory: backend/${{ inputs.component }} - run: npm install --include-workspace-root - - - name: Archive distribution artifact - id: upload - uses: actions/upload-artifact@v4 - with: - name: ${{ inputs.artifact-name }}-${{ inputs.component }} - retention-days: 7 - path: | - express/dist - express/resources - express/src/views - express/assets/images - express/package*.json - express/manifest.yml diff --git a/.github/workflows/deploy-branch.yml b/.github/workflows/deploy-branch.yml index 03cd18ade..9848f8929 100644 --- a/.github/workflows/deploy-branch.yml +++ b/.github/workflows/deploy-branch.yml @@ -19,7 +19,7 @@ permissions: jobs: build-frontend-dependencies: - if: contains(github.event.head_commit.message, '[deploy]') == true +# if: contains(github.event.head_commit.message, '[deploy]') == true name: Build frontend runs-on: ubuntu-latest outputs: @@ -36,7 +36,7 @@ jobs: artifact-name: frontend-build-demo push-frontend-image: - if: contains(github.event.head_commit.message, '[deploy]') == true +# if: contains(github.event.head_commit.message, '[deploy]') == true name: Push frontend image needs: build-frontend-dependencies runs-on: ubuntu-latest @@ -61,12 +61,12 @@ jobs: aws-role-arn: ${{ vars.DEPLOYMENT_ROLE_ARN }} repository: ${{ vars.FRONTEND_CONTAINER_REPOSITORY_NAME }} image-tags: "${{ github.head_ref || github.ref_name }}" - dockerfile: Dockerfile + dockerfile: infrastructure/frontend/Dockerfile artifact-name: frontend-build-demo artifact-path: dist build-frontend-infrastructure: - if: contains(github.event.head_commit.message, '[deploy]') == true +# if: contains(github.event.head_commit.message, '[deploy]') == true name: Build frontend infrastructure needs: push-frontend-image runs-on: ubuntu-latest @@ -104,7 +104,7 @@ jobs: path: .aws-sam/build deploy-frontend: - if: contains(github.event.head_commit.message, '[deploy]') == true +# if: contains(github.event.head_commit.message, '[deploy]') == true name: Deploy frontend needs: [ build-frontend-infrastructure, deploy-api, deploy-cognito, deploy-dynamodb ] runs-on: ubuntu-latest @@ -157,7 +157,7 @@ jobs: echo "url=$url" >> "$GITHUB_OUTPUT" build-dynamo: - if: contains(github.event.head_commit.message, '[deploy]') == true +# if: contains(github.event.head_commit.message, '[deploy]') == true name: Build dynamodb runs-on: ubuntu-latest outputs: @@ -168,7 +168,7 @@ jobs: id: build uses: govuk-one-login/github-actions/sam/build-application@6144f39407b01c9b25b39537b3956deca9e32620 # 22/02/2024 with: - template: backend/dynamodb/cognito.template.yml + template: backend/dynamodb/dynamodb.template.yml base-dir: backend/dynamodb source-dir: backend/dynamodb cache-name: dynamodb-infra @@ -214,7 +214,7 @@ jobs: DeploymentName=${{ steps.get-deployment-name.outputs.pretty-branch-name }} build-cognito: - if: contains(github.event.head_commit.message, '[deploy]') == true +# if: contains(github.event.head_commit.message, '[deploy]') == true name: Build cognito runs-on: ubuntu-latest outputs: @@ -234,7 +234,7 @@ jobs: pull-repository: true deploy-cognito: - if: contains(github.event.head_commit.message, '[deploy]') == true +# if: contains(github.event.head_commit.message, '[deploy]') == true name: Deploy cognito needs: build-cognito runs-on: ubuntu-latest @@ -272,7 +272,7 @@ jobs: DeploymentName=${{ steps.get-deployment-name.outputs.pretty-branch-name }} build-api: - if: contains(github.event.head_commit.message, '[deploy]') == true +# if: contains(github.event.head_commit.message, '[deploy]') == true name: Build api runs-on: ubuntu-latest outputs: @@ -293,7 +293,7 @@ jobs: pull-repository: true deploy-api: - if: contains(github.event.head_commit.message, '[deploy]') == true +# if: contains(github.event.head_commit.message, '[deploy]') == true name: Deploy api needs: build-api runs-on: ubuntu-latest