-
Notifications
You must be signed in to change notification settings - Fork 862
ci: add Slack meeting reminder workflow for OPA Gatekeeper weekly meetings #4277
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
Merged
JaydipGabani
merged 6 commits into
master
from
copilot/add-slack-meeting-reminder-workflow
Dec 4, 2025
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
3a08078
Initial plan
Copilot 7143546
Add Slack meeting reminder workflow for OPA Gatekeeper weekly meetings
Copilot e2661d2
adding slack reminder workflow
JaydipGabani e820b44
Add workflow_dispatch trigger and --fail flag to curl command
Copilot e604c1d
Remove workflow_dispatch trigger and force_run check logic
Copilot 3f2c79d
Merge branch 'master' into copilot/add-slack-meeting-reminder-workflow
JaydipGabani File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,95 @@ | ||
| name: Slack Meeting Reminder | ||
|
|
||
| on: | ||
| schedule: | ||
| # Run every Wednesday at 9 AM PST (5 PM UTC) - 1 hour before 10 AM meeting | ||
| - cron: "0 17 * * 3" | ||
| # Run every Wednesday at 1 PM PST (9 PM UTC) - 1 hour before 2 PM meeting | ||
| - cron: "0 21 * * 3" | ||
|
|
||
| permissions: read-all | ||
|
|
||
| jobs: | ||
| send-reminder: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: Harden Runner | ||
| uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2 | ||
| with: | ||
| egress-policy: audit | ||
|
|
||
| - name: Determine which time slot to use | ||
| id: check-week | ||
| run: | | ||
| # Get the ISO week number | ||
| WEEK_NUM=$(date +%V) | ||
| # Check if it's an even or odd week | ||
| if [ $((WEEK_NUM % 2)) -eq 0 ]; then | ||
| # Even week: 1 PM PST (21:00 UTC) | ||
| EXPECTED_HOUR=21 | ||
| else | ||
| # Odd week: 9 AM PST (17:00 UTC) | ||
| EXPECTED_HOUR=17 | ||
| fi | ||
| CURRENT_HOUR=$(date -u +%H) | ||
| echo "Expected hour: $EXPECTED_HOUR, Current hour: $CURRENT_HOUR" | ||
| if [ "$CURRENT_HOUR" -eq "$EXPECTED_HOUR" ]; then | ||
| echo "should_run=true" >> $GITHUB_OUTPUT | ||
| else | ||
| echo "should_run=false" >> $GITHUB_OUTPUT | ||
| fi | ||
|
|
||
| - name: Send Slack notification | ||
| if: steps.check-week.outputs.should_run == 'true' | ||
| run: | | ||
| curl -X POST -H 'Content-type: application/json' \ | ||
| --fail \ | ||
| --data '{ | ||
| "blocks": [ | ||
| { | ||
| "type": "section", | ||
| "text": { | ||
| "type": "mrkdwn", | ||
| "text": "The OPA Gatekeeper weekly is starting in 1 hour! :clock1:\n\nAdd your agenda items to the meeting notes to get your questions answered by one of the Gatekeeper maintainers.\n\n<https://docs.google.com/document/d/1A1-Q-1OMw3QODs1wT6eqfLTagcGmgzAJAjJihiO3T48/edit|Meeting Notes>" | ||
| } | ||
| }, | ||
| { | ||
| "type": "section", | ||
| "text": { | ||
| "type": "mrkdwn", | ||
| "text": "*Starting time is every Wednesday alternating between:*" | ||
| } | ||
| }, | ||
| { | ||
| "type": "section", | ||
| "text": { | ||
| "type": "mrkdwn", | ||
| "text": "• 10:00 and 14:00 Pacific Time" | ||
| } | ||
| }, | ||
| { | ||
| "type": "section", | ||
| "text": { | ||
| "type": "mrkdwn", | ||
| "text": "• 21:00 and 05:00 Central European Time" | ||
| } | ||
| }, | ||
| { | ||
| "type": "section", | ||
| "text": { | ||
| "type": "mrkdwn", | ||
| "text": "<https://zoom.us/j/332405601|Join Meeting> :point_left:" | ||
| } | ||
| }, | ||
| { | ||
| "type": "context", | ||
| "elements": [ | ||
| { | ||
| "type": "mrkdwn", | ||
| "text": "Check out previous meetings on <https://www.youtube.com/@openpolicyagent8458|YouTube>" | ||
| } | ||
| ] | ||
| } | ||
| ] | ||
| }' \ | ||
| ${{ secrets.SLACK_WEBHOOK_URL }} | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.