-
Notifications
You must be signed in to change notification settings - Fork 0
29 lines (25 loc) · 1.34 KB
/
Copy pathrelease.yml
File metadata and controls
29 lines (25 loc) · 1.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
name: Release
# Trigger on GitHub release
# Pass in app name then build and deploy that specific app to production
on:
release:
types: [published]
# env:
# APP_NAME: ${{ (startsWith(github.event.release.name, 'Resplice') && 'resplice') || (startsWith(github.event.release.name, 'Reauth') && 'reauth') || '' }}
# VERCEL_PROJECT_ID: ${{ (startsWith(github.event.release.name, 'Resplice') && secrets.RESPLICE_VERCEL_PROJECT_ID) || (startsWith(github.event.release.name, 'Reauth') && secrets.REAUTH_VERCEL_PROJECT_ID) || '' }}
# TODO: Make this better
jobs:
ci:
uses: ./.github/workflows/ci.yml
with:
app: ${{ (startsWith(github.event.release.name, 'Resplice') && 'resplice') || (startsWith(github.event.release.name, 'Reauth') && 'reauth') || '' }}
cd:
needs: ci
uses: ./.github/workflows/cd.yml
with:
app: ${{ (startsWith(github.event.release.name, 'Resplice') && 'resplice') || (startsWith(github.event.release.name, 'Reauth') && 'reauth') || '' }}
environment: production
secrets:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ (startsWith(github.event.release.name, 'Resplice') && secrets.RESPLICE_VERCEL_PROJECT_ID) || (startsWith(github.event.release.name, 'Reauth') && secrets.REAUTH_VERCEL_PROJECT_ID) || '' }}
VERCEL_ACCESS_TOKEN: ${{ secrets.VERCEL_ACCESS_TOKEN }}