-
Notifications
You must be signed in to change notification settings - Fork 1
54 lines (47 loc) · 1.49 KB
/
deploy-to-radix.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
name: Deploy to Radix
on:
workflow_call:
inputs:
Environment:
required: true
type: string
VersionTag:
required: true
type: string
secrets:
ClientId:
required: true
TenantId:
required: true
permissions:
id-token: write
contents: read
jobs:
deploy:
runs-on: ubuntu-latest
environment: ${{inputs.Environment}}
steps:
- uses: actions/checkout@v4
- name: 'Az CLI login'
uses: azure/login@v2
with:
client-id: ${{ secrets.ClientId}}
tenant-id: ${{ secrets.TenantId}}
allow-no-subscriptions: true
- name: RADIX Login
run: |
token=$(az account get-access-token --resource 6dae42f8-4368-4678-94ff-3960e28e3630 --query=accessToken -otsv | tr -d '[:space:]')
echo "::add-mask::$token"
echo "APP_SERVICE_ACCOUNT_TOKEN=$token" >> $GITHUB_ENV
- name: 'Deploy API on Radix'
uses: equinor/radix-github-actions@v1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
args: >
create pipeline-job
deploy
--application pepm
--component web
--environment ${{ inputs.Environment }}
--image-tag-name web=${{ inputs.Environment }}:${{ inputs.VersionTag }}
--follow