-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathasset-promotion.yml
More file actions
60 lines (50 loc) · 1.61 KB
/
asset-promotion.yml
File metadata and controls
60 lines (50 loc) · 1.61 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
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
name: Itential Asset Promotion Pipeline
on:
push:
tags:
- "v*"
jobs:
deploy-staging:
if: contains(github.ref, '-rc')
runs-on: ubuntu-latest
environment: staging
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install asyncplatform
run: |
pip install git+https://github.com/Itential/asyncplatform.git
- name: Deploy to Staging
env:
HOST: ${{ secrets.PLATFORM_HOST }}
CLIENT_ID: ${{ secrets.PLATFORM_CLIENT_ID }}
CLIENT_SECRET: ${{ secrets.PLATFORM_CLIENT_SECRET }}
PROJECT_MEMBERS: ${{ vars.PROJECT_MEMBERS }}
run: |
python .github/scripts/deploy.py Staging
deploy-production:
if: startsWith(github.ref, 'refs/tags/v') && !contains(github.ref, '-rc')
runs-on: ubuntu-latest
environment: production
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install asyncplatform
run: |
pip install git+https://github.com/Itential/asyncplatform.git
- name: Deploy to Production
env:
HOST: ${{ secrets.PLATFORM_HOST }}
CLIENT_ID: ${{ secrets.PLATFORM_CLIENT_ID }}
CLIENT_SECRET: ${{ secrets.PLATFORM_CLIENT_SECRET }}
PROJECT_MEMBERS: ${{ vars.PROJECT_MEMBERS }}
run: |
python .github/scripts/deploy.py Production