Skip to content
Merged

new #41

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
8 changes: 4 additions & 4 deletions .github/workflows/rotate-bdba-token.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,19 +50,19 @@ jobs:
run: |
# Authenticate with the GitHub CLI using the generated token
gh auth login --with-token <<< ${{ steps.generate-bdba-token.outputs.token }}

# List of specific repositories to update
# Secrets do not work out of the box for BDBA action
# workflow_run trigger requires GH environments and
# workflow_run trigger requires GH environments and
# environments require repo-scoped secrets
REPOSITORIES=("open-component-model" "ocm-cicd-playground" "ocm-k8s-toolkit" "ocm-controller")

# Loop through each repository and set the secret
for repo in "${REPOSITORIES[@]}"; do
echo "Setting BDBA_API_TOKEN for repository: $repo"
gh secret set BDBA_API_TOKEN \
--repo "open-component-model/$repo" \
--body "${{ steps.generate-bdba-token.outputs.bdba_token }}"
done

echo "BDBA API token successfully rotated for specific repositories at $(date)"
Loading