From 1d0489eb8e7d9ff5b3760aad019be0a7226386d3 Mon Sep 17 00:00:00 2001 From: ChatonDeAru <823314+chatondearu@users.noreply.github.com> Date: Tue, 26 Mar 2024 03:42:42 +0100 Subject: [PATCH] =?UTF-8?q?=F0=9F=92=9A=20ficing=20github=20workflow=20inp?= =?UTF-8?q?uts=20for=20build?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/build.yml | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ff8de0a..9b1fa89 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -2,19 +2,20 @@ name: Build for production on: workflow_dispatch: - envType: - description: "Environment to deploy to" - required: true - default: "prod" - type: choice - options: - - prod - - staging + inputs: + envType: + description: "Environment to deploy to" + required: true + default: "prod" + type: choice + options: + - prod + - staging jobs: build: runs-on: ubuntu-latest - environment: ${{ github.event.inputs.envType }} + environment: ${{ inputs.envType }} steps: - uses: actions/checkout@v4 - name: Login to Scaleway Container Registry @@ -24,6 +25,6 @@ jobs: password: ${{ secrets.SCALEWAY_API_KEY }} registry: ${{ secrets.CONTAINER_REGISTRY_ENDPOINT }} - name: Build the Docker image - run: docker build . -t ${{ secrets.CONTAINER_REGISTRY_ENDPOINT }}/fo-${{ github.event.inputs.envType }} + run: docker build . -t ${{ secrets.CONTAINER_REGISTRY_ENDPOINT }}/fo-${{ inputs.envType }} - name: Push the Docker Image - run: docker push ${{ secrets.CONTAINER_REGISTRY_ENDPOINT }}/fo-${{ github.event.inputs.envType }} + run: docker push ${{ secrets.CONTAINER_REGISTRY_ENDPOINT }}/fo-${{ inputs.envType }}