deployment-status
vercel deploy
を実行し終えた際のステータスが格納されています。
型 | 説明 |
---|---|
"QUEUED" | "BUILDING" | "ERROR" | "INITIALIZING" | "READY" | "CANCELED" | デプロイ後のステータスが文字列で格納されています。 |
使用例
yml
name: Vercel
on:
push:
branches: [main]
pull_request:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
deploy:
name: Deploy
runs-on: ubuntu-latest
permissions:
contents: read
deployments: write
statuses: write
pull-requests: write
steps:
- uses: actions/checkout@v4
- uses: nexterias/actions-vercel@v1
id: vercel
with:
token: ${{ secrets.VERCEL_TOKEN }}
org-id: ${{ secrets.VERCEL_ORG_ID }}
project-id: ${{ secrets.VERCEL_PROJECT_ID }}
production: ${{ github.ref == 'refs/heads/main' }}
- name: Print deployment status
run: echo ${{ steps.vercel.outputs.deployment-status }}