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

Upgrade gh actions #1814

Merged
merged 12 commits into from
May 7, 2024
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
6 changes: 3 additions & 3 deletions .github/workflows/build-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,13 @@ jobs:
uses: docker/setup-buildx-action@0d103c3126aa41d772a8362f6aa67afac040f80c #v3.1.0

- name: DockerHub Registry Login
uses: docker/login-action@343f7c4344506bcbf9b4de18042ae17996df046d
uses: docker/login-action@e92390c5fb421da1463c202d546fed0ec5c39f20
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_TOKEN }}

- name: Github Registry login
uses: docker/login-action@343f7c4344506bcbf9b4de18042ae17996df046d
uses: docker/login-action@e92390c5fb421da1463c202d546fed0ec5c39f20
with:
registry: ghcr.io
username: ${{ github.actor }}
Expand Down Expand Up @@ -77,7 +77,7 @@ jobs:
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || '');

- name: Build and push centrifugeio/centrifuge-chain
uses: docker/build-push-action@0565240e2d4ab88bba5387d719585280857ece09 #v5.1.0
uses: docker/build-push-action@2cdde995de11925a030ce8070c3d77a52ffcf1c0 #v5.1.0
with:
context: .
file: ./docker/centrifuge-chain/Dockerfile
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-wasm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
uses: ./.github/actions/prep-ubuntu

# sccache does not work inside the srtool container
- uses: Swatinem/rust-cache@3cf7f8cc28d1b4e7d01e3783be10a97d55d483c8 # 2.7
- uses: Swatinem/rust-cache@23bce251a8cd2ffc3c1075eaa2367cf899916d84 # 2.7
with:
prefix-key: build
shared-key: wasm
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deploy-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
echo "<meta http-equiv=\"refresh\" content=\"0; url=centrifuge_chain/index.html\">" \ > ./target/doc/index.html

- name: Setup Pages
uses: actions/configure-pages@v4
uses: actions/configure-pages@v5

- name: Fix permissions
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/try-runtime.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Notify Slack
uses: rtCamp/action-slack-notify@b24d75fe0e728a4bf9fc42ee217caa686d141ee8 #v2.2.1
uses: rtCamp/action-slack-notify@4e5fb42d249be6a45a298f3c9543b111b02f7907 #v2.3.0
env:
SLACK_CHANNEL: eng-protocol-general
SLACK_COLOR: '#FF0000'
Expand Down
18 changes: 18 additions & 0 deletions scripts/upgrade-github-actions.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
#!/bin/bash
# This script will use the open dependabot PRs to peform an upgrade of all GH actions

# The target branch to merge all Dependabot PRs into
TARGET_BRANCH="upgrade-gh-actions"

# Ensure the target branch exists and is checked out
git checkout -b $TARGET_BRANCH 2>/dev/null || git checkout $TARGET_BRANCH

# Fetch all PRs from GitHub, filter for those opened by Dependabot, and extract their branch names
gh pr list --search "author:app/dependabot" --state open --json headRefName --jq '.[].headRefName' | while read branch; do
# Merge each Dependabot branch into the target branch
echo "Merging $branch into $TARGET_BRANCH..."
git merge origin/$branch --no-edit
done

# After merging, you might want to push the changes
# git push origin $TARGET_BRANCH
Loading