-
Notifications
You must be signed in to change notification settings - Fork 0
64 lines (58 loc) · 1.83 KB
/
deploy.yml
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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: Deploy
on:
workflow_call:
inputs:
org-alias:
required: false
type: string
default: 'sandbox'
datadog:
required: false
type: boolean
default: false
newrelic:
required: false
type: boolean
default: false
secrets:
DEVHUB_SFDX_AUTH_URL:
required: true
ENV_SFDX_AUTH_URL:
required: true
DATADOG_HOST:
required: false
DATADOG_API_KEY:
required: false
NEWRELIC_INSIGHT_INSERT_KEYS:
required: false
env:
SFPOWERSCRIPTS_NEWRELIC: "${{ inputs.newrelic }}"
SFPOWERSCRIPTS_NEWRELIC_API_KEY: '${{ secrets.NEWRELIC_INSIGHT_INSERT_KEYS }}'
SFPOWERSCRIPTS_DATADOG: "${{ inputs.datadog }}"
SFPOWERSCRIPTS_DATADOG_HOST: "${{ secrets.DATADOG_HOST }}"
SFPOWERSCRIPTS_DATADOG_API_KEY: "${{ secrets.DATADOG_API_KEY }}"
jobs:
deploy:
name: 'Deploy to ${{ inputs.org-alias }} environment'
runs-on: ubuntu-latest
container: ghcr.io/flxbl-io/sfp-rc:alpha
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/download-artifact@v2
with:
name: quickbuild-artifacts
path: artifacts
- name: 'Authenticate Dev Hub'
run: |
echo "${{ secrets.DEVHUB_SFDX_AUTH_URL }}" > ./authfile
sf org login sfdx-url -f authfile -a devhub
- name: 'Authenticate to ${{ inputs.org-alias }}'
run: |
echo "${{ secrets.ENV_SFDX_AUTH_URL }}" > ./env_authfile
sf org login sfdx-url -f ./env_authfile -a ${{ inputs.org-alias }}
- name: 'Deploy to ${{ inputs.org-alias }}'
run: |
sfp dependency install -u ${{ inputs.org-alias }} -v devhub
sfp deploy -u ${{ inputs.org-alias }} --skipifalreadyinstalled -g "::group::,::endgroup::"