From 4d8554690126f5403dd249727f1ac168fa5ee918 Mon Sep 17 00:00:00 2001 From: John Parkhurst Date: Wed, 11 Jun 2025 12:58:59 -0400 Subject: [PATCH 1/2] Update Dockerfile --- web/Dockerfile | 1 + 1 file changed, 1 insertion(+) diff --git a/web/Dockerfile b/web/Dockerfile index bb9805c..43b4327 100644 --- a/web/Dockerfile +++ b/web/Dockerfile @@ -12,6 +12,7 @@ RUN npm ci COPY . ./ EXPOSE 5173 +EXPOSE 5171 CMD ["npm", "run", "dev"] From 1277b258342fb7b30c265ac5379ab2adccf4197b Mon Sep 17 00:00:00 2001 From: Matt DiMeglio Date: Wed, 11 Jun 2025 13:15:27 -0400 Subject: [PATCH 2/2] Update web-deploy.yml --- .github/workflows/web-deploy.yml | 37 +++++++++++++++++++++++++++++++- 1 file changed, 36 insertions(+), 1 deletion(-) diff --git a/.github/workflows/web-deploy.yml b/.github/workflows/web-deploy.yml index 0faa842..9f1ed7c 100644 --- a/.github/workflows/web-deploy.yml +++ b/.github/workflows/web-deploy.yml @@ -1,6 +1,16 @@ name: Web Deployment on: workflow_dispatch: {} + workflow_call: + inputs: + develop-environments: + type: string + description: An optional list of dev environments to deploy to. + default: '["dev"]' + release-environments: + type: string + description: An optional list of release environments to deploy to. + default: '["prod"]' pull_request: branches: - main @@ -15,8 +25,33 @@ on: paths: - web/** jobs: + determine-workflow: + runs-on: 'ubuntu-latest' + outputs: + workflow_type: ${{ steps.workflow.outputs.workflow_type }} + workflow_envs: ${{ steps.workflow.outputs.workflow_envs }} + release_type: ${{ steps.workflow.outputs.release_type }} + steps: + - name: Determine Workflow + id: workflow + shell: bash + run: | + event=${{ github.event_name }} + workflow_type='dev'; + workflow_envs='${{ inputs.develop-environments }}' + if [[ $event == 'workflow_dispatch' && ${{ github.ref_name }}' == 'main' ]]; + then + workflow_type='release'; + workflow_envs='${{ inputs.release-environments }}' + fi + + echo "workflow_type=$workflow_type" >> $GITHUB_OUTPUT + echo "workflow_envs=$workflow_envs" >> $GITHUB_OUTPUT + + echo "Running #workflow_type pipeline in environments: $workflow_envs" >> $GITHUB_STEP_SUMMARY build: environment: dev + needs: determine-workflow runs-on: 'ubuntu-latest' permissions: contents: read @@ -36,7 +71,7 @@ jobs: deploy: environment: dev needs: build - if: always() && needs.build.result == 'success' + if: always() && needs.build.result == 'success' && ${{ steps.workflow.outputs.workflow_type }} == 'release' runs-on: 'ubuntu-latest' permissions: contents: read