forked from notthebee/infra
-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (28 loc) · 900 Bytes
/
cd.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
name: CD
on:
push:
branches: [ main, add-cd-for-kustomize ]
jobs:
deploy:
runs-on: [self-hosted, linux, x64]
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Generate Kubeconfig and Certs
run: |
mkdir -p ${{ github.workspace }}/out
echo "${{ secrets.KUBECONFIG }}" > ${{ github.workspace }}/out/deploy.kubeconfig
- name: Deploy
env:
ANSIBLE_PASSWORD: ${{ secrets.ANSIBLE_PASSWORD }}
KUBECONFIG: ${{ github.workspace }}/out/deploy.kubeconfig
run: |
./deployment/automation/deploy.sh