Skip to content

Commit

Permalink
test workflow
Browse files Browse the repository at this point in the history
Signed-off-by: Tao Liu <[email protected]>
  • Loading branch information
Flyingliuhub committed Oct 29, 2024
1 parent 0f29eef commit 08c7b51
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 69 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/deployment-template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ on:
esnode_key_cert:
required: false
root_ca_cert:
required: false
required: false
jobs:

OS-OSD-Deployment:
Expand All @@ -68,7 +68,7 @@ jobs:
KIBANASERVER: ${{ secrets.kibanaserver }}

- name: Step 2 - Replace Token in opensearch.yml
if: ${{ (inputs.deploy-env == 'dev') || (inputs.deploy-env == 'prod') }}
if: ${{ (inputs.deploy-env == 'dev') || (inputs.deploy-env == 'prod') || (inputs.deploy-env == 'preview') }}
uses: cschleiden/replace-tokens@v1
with:
files: '["${{ github.workspace }}/config/playground/helm/${{inputs.deploy-env}}/helm-opensearch.yaml"]'
Expand Down
74 changes: 8 additions & 66 deletions .github/workflows/os-osd-deployment-scheduled.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ on:
workflow_dispatch:
# Adds schdeule event trigger for daily reset.
# https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#schedule
schedule:
# Run daily at 04:30 UTC.
- cron: '30 04 * * *'
# schedule:
# # Run daily at 04:30 UTC.
# - cron: '30 04 * * *'
jobs:

OS-OSD-Preview-Scheduled-Deployment:
uses: opensearch-project/dashboards-anywhere/.github/workflows/deployment-template.yml@main
uses: opensearch-project/dashboards-anywhere/.github/workflows/deployment-template.yml@release-218
with:
helm-repo: https://opensearch-project.github.io/helm-charts/
deploy-env: preview
Expand All @@ -32,49 +32,9 @@ jobs:
otel_root_ca: ${{ secrets.OTEL_ROOT_CA }}
otel_data_prepper_cert: ${{ secrets.OTEL_DATA_PREPPER_CERT }}
kibanaserver: ${{ secrets.KIBANASERVER }}

OS-OSD-SearchApps-Scheduled-Deployment:
uses: opensearch-project/dashboards-anywhere/.github/workflows/deployment-template.yml@main
with:
helm-repo: https://opensearch-project.github.io/helm-charts/
deploy-env: searchapps
secrets:
access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_SEARCHAPPS }}
secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_SEARCHAPPS }}
region: ${{ secrets.AWS_REGION_SEARCHAPPS }}
kube-config: ${{ secrets.KUBE_CONFIG_DATA_SEARCHAPPS }}
openid_client_id: ${{ secrets.OPENID_CLIENT_ID_SEARCHAPPS }}
openid_client_secret: ${{ secrets.OPENID_CLIENT_SECRET_SEARCHAPPS }}
openid_base_redirect_url: ${{ secrets.OPENID_BASE_REDIRECT_URL_SEARCHAPPS }}
openid_logout_url: ${{ secrets.OPENID_LOGOUT_URL_SEARCHAPPS }}
ga-tracking-id: ${{ secrets.GA_TRACKING_ID }}
osd_user: ${{ secrets.OSD_USER_SEARCHAPPS }}
osd_user_password: ${{ secrets.OSD_USER_PASSWORD_SEARCHAPPS }}
otel_root_ca: ${{ secrets.OTEL_ROOT_CA }}
otel_data_prepper_cert: ${{ secrets.OTEL_DATA_PREPPER_CERT }}
kibanaserver: ${{ secrets.KIBANASERVER }}

OS-OSD-Observability-Scheduled-Deployment:
uses: opensearch-project/dashboards-anywhere/.github/workflows/deployment-template.yml@main
with:
helm-repo: https://opensearch-project.github.io/helm-charts/
deploy-env: observability
secrets:
access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID_OBSERVABILITY }}
secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY_OBSERVABILITY }}
region: ${{ secrets.AWS_REGION_OBSERVABILITY }}
kube-config: ${{ secrets.KUBE_CONFIG_DATA_OBSERVABILITY }}
openid_client_id: ${{ secrets.OPENID_CLIENT_ID_OBSERVABILITY }}
openid_client_secret: ${{ secrets.OPENID_CLIENT_SECRET_OBSERVABILITY }}
openid_base_redirect_url: ${{ secrets.OPENID_BASE_REDIRECT_URL_OBSERVABILITY }}
openid_logout_url: ${{ secrets.OPENID_LOGOUT_URL_OBSERVABILITY }}
ga-tracking-id: ${{ secrets.GA_TRACKING_ID }}
osd_user: ${{ secrets.OSD_USER_OBSERVABILITY }}
osd_user_password: ${{ secrets.OSD_USER_PASSWORD_OBSERVABILITY }}
otel_root_ca: ${{ secrets.OTEL_ROOT_CA }}
otel_data_prepper_cert: ${{ secrets.OTEL_DATA_PREPPER_CERT }}
kibanaserver: ${{ secrets.KIBANASERVER }}
query_datasources_master_key: ${{ secrets.QUERY_DATASOURCES_MASTER_KEY }}
esnode_cert: ${{ secrets.ESNODE_CERT }}
esnode_key_cert: ${{ secrets.ESNODE_KEY_CERT }}
root_ca_cert: ${{ secrets.ROOT_CA_CERT }}

OSD-Functional-Test-Preview:
needs: OS-OSD-Preview-Scheduled-Deployment
Expand All @@ -83,22 +43,4 @@ jobs:
endpoint: https://reinvent.playground.opensearch.org
secrets:
osd-user: ${{ secrets.OSD_USER_PREVIEW }}
osd-user-password: ${{ secrets.OSD_USER_PASSWORD_PREVIEW }}

OSD-Functional-Test-SearchApps:
needs: OS-OSD-SearchApps-Scheduled-Deployment
uses: opensearch-project/dashboards-anywhere/.github/workflows/functional-test-template.yml@searchapps
with:
endpoint: https://searchapps.playground.opensearch.org
secrets:
osd-user: ${{ secrets.OSD_USER_SEARCHAPPS }}
osd-user-password: ${{ secrets.OSD_USER_PASSWORD_SEARCHAPPS }}

OSD-Functional-Test-Observability:
needs: OS-OSD-Observability-Scheduled-Deployment
uses: opensearch-project/dashboards-anywhere/.github/workflows/functional-test-template.yml@observability
with:
endpoint: https://observability.playground.opensearch.org
secrets:
osd-user: ${{ secrets.OSD_USER_OBSERVABILITY }}
osd-user-password: ${{ secrets.OSD_USER_PASSWORD_OBSERVABILITY }}
osd-user-password: ${{ secrets.OSD_USER_PASSWORD_PREVIEW }}
Original file line number Diff line number Diff line change
Expand Up @@ -201,4 +201,4 @@ extraObjects: []
# specify the external plugins to install
plugins:
enabled: true
installList: ["https://github.com/BionIT/google-analytics-plugin/releases/download/2.11.0/googleAnalytics-2.11.0.zip"]
installList: ["https://github.com/BionIT/google-analytics-plugin/releases/download/2.18.0/googleAnalytics-2.18.0.zip"]
7 changes: 7 additions & 0 deletions config/playground/helm/preview/helm-opensearch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,12 @@ majorVersion: "7"
opensearchHome: /usr/share/opensearch
# such as opensearch.yml
config:
esnode.pem: |-
${ESNODE_CERT}
esnode-key.pem: |-
${ESNODE_KEY_CERT}
root-ca.pem: |-
${ROOT_CA_CERT}
opensearch.yml: |
cluster.name: opensearch-cluster
# Bind to all interfaces because we don't know what IP address Docker will assign to us.
Expand Down Expand Up @@ -723,6 +729,7 @@ securityConfig:
- cluster:admin/opensearch/securityanalytics/findings/get
- cluster:admin/opensearch/securityanalytics/alerts/get
- cluster:admin/opensearch/securityanalytics/detector/get
- cluster:admin/opensearch/securityanalytics/logtype/search
# For using sql join query
- "indices:data/read/scroll*"
index_permissions:
Expand Down

0 comments on commit 08c7b51

Please sign in to comment.