Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: change cron and enable slack notify for ppc64le e2e #821

Merged
merged 2 commits into from
Aug 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 14 additions & 13 deletions .github/workflows/e2e-nightly-ppc64le.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
description: 'quay-operator-index tag. Defaults to 3.10-unstable'
required: false
schedule:
- cron: '15 11 * * *'
- cron: '0 0 * * 3,5'

jobs:
deploy:
Expand Down Expand Up @@ -74,15 +74,16 @@ jobs:
run: |
./hack/ppc64le/destroy_cluster.sh

# - name: Notify slack
# if: ${{ always() }}
# uses: rtCamp/action-slack-notify@v2
# env:
# SLACK_CHANNEL: team-quay-bots
# SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
# SLACK_COLOR: ${{ job.status }}
# SLACK_TITLE: "${{ github.workflow }}: ${{ job.status }}"
# SLACK_MESSAGE: |
# * **Repo**: ${{ github.repository }}
# * **Workflow**: ${{ github.workflow }}
# * **Result**: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
- name: Notify slack
if: ${{ always() }}
uses: rtCamp/action-slack-notify@v2
env:
SLACK_CHANNEL: team-quay-bots
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
SLACK_COLOR: ${{ job.status }}
SLACK_TITLE: "${{ github.workflow }}: ${{ job.status }}"
SLACK_MESSAGE: |
* **Repo**: ${{ github.repository }}
* **Workflow**: ${{ github.workflow }}
* **Result**: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}
* **Contact**: @yshaikh
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dmage Note I have added my mention here. Let me know if that is not okay.

21 changes: 20 additions & 1 deletion hack/ppc64le/destroy_cluster.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,25 @@ function info {
echo "INFO $(date '+%Y-%m-%dT%H:%M:%S') $*"
}


NO_OF_RETRY=${NO_OF_RETRY:-"3"}
function retry {
cmd=$1
for i in $(seq 1 "$NO_OF_RETRY"); do
echo "Attempt: $i/$NO_OF_RETRY"
ret_code=0
$cmd || ret_code=$?
if [ $ret_code = 0 ]; then
break
elif [ "$i" == "$NO_OF_RETRY" ]; then
echo "All retry attempts failed!"
exit $ret_code
else
sleep 10
fi
done
}

CLUSTER_ID=quay-e2e
OCP_INSTALL_DIR=quaye2e
CCO_DIR=ccodir
Expand All @@ -21,5 +40,5 @@ fi

if [[ -f ./openshift-install ]]; then
info 'destroying the cluster...'
./openshift-install destroy cluster --dir $OCP_INSTALL_DIR --log-level=info
retry "./openshift-install destroy cluster --dir $OCP_INSTALL_DIR --log-level=info"
fi
Loading