-
Notifications
You must be signed in to change notification settings - Fork 30
112 lines (100 loc) · 4.23 KB
/
os-osd-deployment.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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
# This workflow was used for deploying the latest version of OpenSearch
# and OpenSearch Dashboards to AWS EKS (Elastic Kubernetes Service) cluster.
name: Deploy OpenSearch and OpenSearch Dashboards
on:
push:
branches: [ main ]
# adds workflow_dispatch for manually running a workflow
workflow_dispatch:
jobs:
Pre-Deployment:
runs-on: ubuntu-latest
outputs:
config_change_dev: ${{steps.filter.outputs.dev}}
config_change_prod: ${{steps.filter.outputs.prod}}
config_change_ml: ${{steps.filter.outputs.ml}}
steps:
- uses: actions/checkout@v3
- uses: dorny/paths-filter@v2
id: filter
with:
# creates filters to check if any dev or prod changes
filters: |
dev:
- 'config/playground/helm/dev/**'
prod:
- 'config/playground/helm/prod/**'
ml:
- 'config/playground/helm/ml/**'
OS-OSD-Dev-Deployment:
needs: Pre-Deployment
if: ${{ needs.Pre-Deployment.outputs.config_change_dev == 'true' }}
uses: opensearch-project/dashboards-anywhere/.github/workflows/deployment-template.yml@main
with:
helm-repo: https://opensearch-project.github.io/helm-charts/
deploy-env: dev
secrets:
access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_DEV }}
secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_DEV }}
region: ${{ secrets.AWS_REGION_DEV }}
kube-config: ${{ secrets.KUBE_CONFIG_DATA_DEV }}
ga-tracking-id: ${{ secrets.GA_TRACKING_ID }}
kibanaserver: ${{ secrets.KIBANASERVER }}
esnode_cert: ${{ secrets.ESNODE_CERT }}
esnode_key_cert: ${{ secrets.ESNODE_KEY_CERT }}
root_ca_cert: ${{ secrets.ROOT_CA_CERT }}
OS-OSD-Prod-Deployment:
needs: Pre-Deployment
if: ${{ needs.Pre-Deployment.outputs.config_change_prod == 'true'}}
uses: opensearch-project/dashboards-anywhere/.github/workflows/deployment-template.yml@main
with:
helm-repo: https://opensearch-project.github.io/helm-charts/
deploy-env: prod
secrets:
access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_PROD }}
secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_PROD }}
region: ${{ secrets.AWS_REGION_PROD }}
kube-config: ${{ secrets.KUBE_CONFIG_DATA_PROD }}
kibanaserver: ${{ secrets.KIBANASERVER }}
ga-tracking-id: ${{ secrets.GA_TRACKING_ID_PROD }}
esnode_cert: ${{ secrets.ESNODE_CERT }}
esnode_key_cert: ${{ secrets.ESNODE_KEY_CERT }}
root_ca_cert: ${{ secrets.ROOT_CA_CERT }}
OS-OSD-ML-Deployment:
needs: Pre-Deployment
if: ${{ needs.Pre-Deployment.outputs.config_change_ml == 'true' }}
uses: opensearch-project/dashboards-anywhere/.github/workflows/deployment-template.yml@main
with:
helm-repo: https://opensearch-project.github.io/helm-charts/
deploy-env: ml
secrets:
access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_ML }}
secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_ML }}
region: ${{ secrets.AWS_REGION_ML }}
kube-config: ${{ secrets.KUBE_CONFIG_DATA_ML }}
ga-tracking-id: ${{ secrets.GA_TRACKING_ID }}
kibanaserver: ${{ secrets.KIBANASERVER }}
OSD-Functional-Test-Dev:
needs: OS-OSD-Dev-Deployment
uses: opensearch-project/dashboards-anywhere/.github/workflows/functional-test-template.yml@main
with:
endpoint: https://playground.opensearch.oss.aws.dev
secrets:
osd-user: ${{ secrets.OSD_USER_DEV }}
osd-user-password: ${{ secrets.OSD_USER_PASSWORD_DEV }}
OSD-Functional-Test-Prod:
needs: OS-OSD-Prod-Deployment
uses: opensearch-project/dashboards-anywhere/.github/workflows/functional-test-template.yml@main
with:
endpoint: https://playground.opensearch.org
secrets:
osd-user: ${{ secrets.OSD_USER_PROD }}
osd-user-password: ${{ secrets.OSD_USER_PASSWORD_PROD }}
OSD-Functional-Test-ML:
needs: OS-OSD-ML-Deployment
uses: opensearch-project/dashboards-anywhere/.github/workflows/functional-test-template.yml@main
with:
endpoint: https://ml.playground.opensearch.org
secrets:
osd-user: ${{ secrets.OSD_USER_ML }}
osd-user-password: ${{ secrets.OSD_USER_PASSWORD_ML }}