Skip to content

Commit

Permalink
Add log check step for both workflows
Browse files Browse the repository at this point in the history
Signed-off-by: Ryan Liang <[email protected]>
  • Loading branch information
RyanL1997 committed Nov 29, 2023
1 parent 6462587 commit 6abffa4
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/cypress-test-oidc-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,11 @@ jobs:
echo 'HERE IS THE DASHBOARD CONFIG'
cat ./config/opensearch_dashboards.yml
nohup yarn start --no-base-path --no-watch | tee dashboard.log &
- name : Check If OpenSearch Dashboard is ready
if: ${{ runner.os == 'Linux' }}
run: |
cd ./OpenSearch-Dashboards
for i in {1..60}; do
if grep -q "bundles compiled successfully after" "dashboard.log"; then
echo "OpenSearch Dashboards compiled successfully."
Expand Down
19 changes: 17 additions & 2 deletions .github/workflows/cypress-test-saml-e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,23 @@ jobs:
EOT
echo 'HERE IS THE DASHBOARD CONFIG'
cat ./config/opensearch_dashboards.yml
nohup yarn start --no-base-path --no-watch &
sleep 600
nohup yarn start --no-base-path --no-watch | tee dashboard.log &
- name : Check If OpenSearch Dashboard is ready
if: ${{ runner.os == 'Linux' }}
run: |
cd ./OpenSearch-Dashboards
for i in {1..60}; do
if grep -q "bundles compiled successfully after" "dashboard.log"; then
echo "OpenSearch Dashboards compiled successfully."
break
fi
if [ $i -eq 60 ]; then
echo "Timeout for 600 seconds reached. OpenSearch Dashboards did not finish compiling."
exit 1
fi
sleep 10
done
- name: Run Cypress
run : |
Expand Down

0 comments on commit 6abffa4

Please sign in to comment.