Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: add env check for prod #8

Merged
merged 1 commit into from
Jan 24, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions .github/workflows/deploy-manual.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,19 @@ jobs:
name: Deploy
runs-on: ubuntu-latest
steps:
- name: Checkout ${{ github.event.inputs.tag }}
- name: Check environment
run: |
if [[ "${{ github.event.inputs.environment }}" == "prod" ]]; then
echo "Cannot run this job with 'prod' environment"
exit 1
fi

- name: Checkout
uses: actions/checkout@v4

- name: Get Tag
id: get_version
run: echo ::set-output name=VERSION::${GITHUB_REF#refs/tags/}
run: echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT

outputs:
version: ${{ steps.get_version.outputs.VERSION }}
Expand Down