diff --git a/.github/workflows/deploy-dev.yml b/.github/workflows/deploy-dev.yml new file mode 100644 index 0000000..4870b0b --- /dev/null +++ b/.github/workflows/deploy-dev.yml @@ -0,0 +1,31 @@ +name: Deploy develop + +on: + pull_request: + +jobs: + deploy: + name: Deploy + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - uses: actions/checkout@v2 + with: + repository: darwinia-network/devops + path: .github + + - uses: ./.github/actions/smart-vercel + name: Deploy to Vercel + with: + vercel_token: ${{ secrets.VERCEL_TOKEN }} + vercel_group: itering + preview_output: true + project_name: msgport-home + dist_path: dist + alias_domain: "msgport-home-dev" + enable_cache: true + enable_notify_comment: true + enable_notify_slack: true + slack_channel: public-msgport + slack_webhook: ${{ secrets.SLACK_INCOMING_WEBHOOK_URL }} diff --git a/.github/workflows/deploy-prd.yml b/.github/workflows/deploy-prd.yml new file mode 100644 index 0000000..b6ebaf7 --- /dev/null +++ b/.github/workflows/deploy-prd.yml @@ -0,0 +1,32 @@ +name: Deploy production + +on: + push: + tags: + - 'v*' + +jobs: + deploy: + name: Deploy + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - uses: actions/checkout@v2 + with: + repository: darwinia-network/devops + path: .github + + - uses: ./.github/actions/smart-vercel + name: Deploy to Vercel + with: + vercel_token: ${{ secrets.VERCEL_TOKEN }} + vercel_group: itering + preview_output: true + project_name: msgport-home + dist_path: dist + prod_mode: true + enable_cache: true + enable_notify_slack: true + slack_channel: public-msgport + slack_webhook: ${{ secrets.SLACK_INCOMING_WEBHOOK_URL }} diff --git a/.github/workflows/deploy-stg.yml b/.github/workflows/deploy-stg.yml new file mode 100644 index 0000000..4e588e5 --- /dev/null +++ b/.github/workflows/deploy-stg.yml @@ -0,0 +1,32 @@ +name: Deploy staging + +on: + push: + branches: [main] + +jobs: + deploy: + name: Deploy + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - uses: actions/checkout@v2 + with: + repository: darwinia-network/devops + path: .github + + - uses: ./.github/actions/smart-vercel + name: Deploy to Vercel + id: smart-vercel + with: + vercel_token: ${{ secrets.VERCEL_TOKEN }} + vercel_group: itering + preview_output: true + project_name: msgport-home + dist_path: dist + alias_domain: "msgport-home-stg" + enable_cache: true + enable_notify_slack: true + slack_channel: public-msgport + slack_webhook: ${{ secrets.SLACK_INCOMING_WEBHOOK_URL }}