-
Notifications
You must be signed in to change notification settings - Fork 17
86 lines (82 loc) · 3.51 KB
/
deploy-production.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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
name: Deploy Production
on:
workflow_dispatch:
jobs:
deploy-deeplynx-prod:
runs-on: [ self-hosted ]
environment: production
steps:
- name: Checkout
uses: actions/checkout@v3
with:
path: deeplynx
ref: main
- name: Checkout tools repo
uses: actions/checkout@v3
with:
repository: Digital-Engineering/kubernetes
ref: main
path: kubernetes
token: ${{ secrets.GH_TOKEN }}
- shell: bash
name: Manifest env substitute
env:
CI_REGISTRY: ${{ secrets.CI_REGISTRY}}
CI_REGISTRY_PATH: ${{ secrets.CI_REGISTRY_PATH}}
DB_NAME: ${{ secrets.DB_NAME }}
AZURE_BLOB_CONTAINER_NAME: ${{ secrets.AZURE_BLOB_CONTAINER_NAME }}
CONTAINER_INVITE_URL: ${{ secrets.CONTAINER_INVITE_URL }}
FILE_STORAGE_METHOD: ${{ secrets.FILE_STORAGE_METHOD}}
SMTP_HOST: ${{ secrets.SMTP_HOST}}
SMTP_TLS: ${{ secrets.SMTP_TLS}}
EMAIL_ADDRESS: ${{ secrets.EMAIL_ADDRESS}}
EMAIL_ENABLED: ${{ secrets.EMAIL_ENABLED}}
EMAIL_VALIDATION_ENFORCED: ${{ secrets.EMAIL_VALIDATION_ENFORCED}}
ROOT_ADDRESS: ${{ secrets.ROOT_ADDRESS }}
ENCRYPTION_KEY_PATH: ${{ secrets.ENCRYPTION_KEY_PATH }}
NODE_ENV: ${{ secrets.NODE_ENV }}
AUTH_STRATEGY: ${{ secrets.AUTH_STRATEGY }}
BASE_URL: ${{ secrets.BASE_URL }}
SAML_ENABLED: ${{ secrets.SAML_ENABLED }}
SAML_ADFS_ENTRY_POINT: ${{ secrets.SAML_ADFS_ENTRY_POINT }}
SAML_ADFS_ISSUER: ${{ secrets.SAML_ADFS_ISSUER }}
SAML_ADFS_CALLBACK: ${{ secrets.SAML_ADFS_CALLBACK }}
SAML_ADFS_PRIVATE_CERT_PATH: ${{ secrets.SAML_ADFS_PRIVATE_CERT_PATH }}
SAML_ADFS_PUBLIC_CERT_PATH: ${{ secrets.SAML_ADFS_PUBLIC_CERT_PATH }}
SAML_ADFS_CLAIMS_EMAIL: ${{ secrets.SAML_ADFS_CLAIMS_EMAIL }}
SAML_ADFS_CLAIMS_NAME: ${{ secrets.SAML_ADFS_CLAIMS_NAME }}
SERVAL_URL: ${{secrets.SERVAL_URL}}
PROCESS_QUEUE_NAME: ${{ secrets.PROCESS_QUEUE_NAME }}
EVENTS_QUEUE_NAME: ${{ secrets.EVENTS_QUEUE_NAME }}
DATA_SOURCES_QUEUE_NAME: ${{ secrets.DATA_SOURCES_QUEUE_NAME }}
CACHE_PROVIDER: ${{ secrets.CACHE_PROVIDER }}
CACHE_REDIS_CONNECTION_STRING: ${{ secrets.CACHE_REDIS_CONNECTION_STRING }}
EDGE_INSERTION_QUEUE_NAME: ${{ secrets.EDGE_INSERTION_QUEUE_NAME }}
QUEUE_SYSTEM: ${{ secrets.QUEUE_SYSTEM }}
TIMESCALEDB_ENABLED: ${{ secrets.TIMESCALEDB_ENABLED }}
TZ: ${{ secrets.TZ }}
CI_COMMIT_SHA: $GITHUB_SHA
NODE_EXTRA_CA_CERTS: ${{ secrets.NODE_EXTRA_CA_CERTS }}
RUN_JOBS: ${{ secrets.RUN_JOBS }}
ELM_HOST: ${{ secrets.ELM_HOST }}
ELM_IP: ${{ secrets.ELM_IP }}
NETWORKING_HOST: ${{ secrets.NETWORKING_HOST }}
run: |
cd $GITHUB_WORKSPACE/kubernetes/deeplynx/manifests
envsubst < production.yml > production_final.yml
- uses: azure/setup-kubectl@v3
- uses: azure/k8s-set-context@v3
with:
method: kubeconfig
kubeconfig: ${{ secrets.KUBE_CONFIG }}
context: deploy-service-account
- uses: Azure/k8s-deploy@v4
with:
resource-group: ${{ secrets.CI_RESOURCE_GROUP }}
name: ${{ secrets.CLUSTER_NAME }}
namespace: deeplynx-prd
action: deploy
force: true
strategy: basic
manifests: |
kubernetes/deeplynx/manifests/production_final.yml