Skip to content

Commit 14aaefd

Browse files
committed
feat: Updated code to use environment from payload if inputs does not exist
1 parent 7728459 commit 14aaefd

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

.github/workflows/build-push.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ jobs:
4848
steps:
4949
- name: Output variables
5050
run: |
51-
echo "Environment: ${{ inputs.environment }}"
51+
echo "Environment: ${{ inputs.environment || github.event.client_payload.environment }}"
5252
echo "Branch: ${{ github.ref }}"
5353
- name: Checks to see that main branch is selected if deploying to prod
5454
if: ${{ inputs.environment == 'prod' && github.ref != 'refs/heads/main' }}
@@ -65,7 +65,7 @@ jobs:
6565
docs_source_path: "public"
6666
docs_build_path: "./"
6767
doc_type: "hugo"
68-
environment: ${{inputs.environment}}
68+
environment: ${{ inputs.environment || github.event.client_payload.environment }}
6969
force_hugo_theme_version: ${{inputs.hugo_theme_override}}
7070
auto_deploy_branch: "main"
7171
auto_deploy_env: "prod"

0 commit comments

Comments
 (0)