Update components #36
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
| --- | |
| name: Update components | |
| on: | |
| workflow_dispatch: {} | |
| schedule: | |
| - cron: "0 0 * * *" | |
| env: | |
| GIT_AUTHOR_NAME: OpenVoxProjectBot | |
| GIT_AUTHOR_EMAIL: 215568489+OpenVoxProjectBot@users.noreply.github.com | |
| GIT_COMMITTER_NAME: OpenVoxProjectBot | |
| GIT_COMMITTER_EMAIL: 215568489+OpenVoxProjectBot@users.noreply.github.com | |
| SSH_AUTH_SOCK: /tmp/ssh_agent.sock | |
| permissions: | |
| contents: read | |
| jobs: | |
| update_gems: | |
| name: 'Update gem components' | |
| runs-on: ubuntu-24.04 | |
| if: github.repository_owner == 'OpenVoxProject' | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: Setup Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: 'ruby' | |
| bundler-cache: true | |
| - name: Add SSH key | |
| run: | | |
| mkdir -p ~/.ssh | |
| echo "${{ secrets.OPENVOXBOT_SSH_PRIVATE_KEY }}" > ~/.ssh/github_actions | |
| chmod 600 ~/.ssh/github_actions | |
| ssh-agent -a $SSH_AUTH_SOCK > /dev/null | |
| ssh-add ~/.ssh/github_actions | |
| - name: Setup git | |
| run: | | |
| git config --global user.email "$GIT_AUTHOR_EMAIL" | |
| git config --global user.name "$GIT_AUTHOR_NAME" | |
| git config --global gpg.format ssh | |
| git config --global user.signingkey ~/.ssh/github_actions | |
| git config --global commit.gpgsign true | |
| git config --global tag.gpgsign true | |
| - name: Display bundle environment | |
| run: bundle env | |
| - name: Check for gem updates | |
| run: bundle exec rake vox:update_gems | |
| - name: Create pull Request | |
| uses: peter-evans/create-pull-request@v8 | |
| with: | |
| commit-message: "Update Ruby components" | |
| signoff: true | |
| branch: "component-update" | |
| delete-branch: true | |
| title: "Update Ruby components" | |
| token: '${{ secrets.OPENVOXBOT_COMMIT_AND_PRS }}' | |
| assignees: '${{ github.triggering_actor }}' | |
| author: '${{ env.GIT_AUTHOR_NAME }} <${{ env.GIT_AUTHOR_EMAIL }}>' | |
| committer: '${{ env.GIT_COMMITTER_NAME }} <${{ env.GIT_COMMITTER_EMAIL }}>' | |
| body: | | |
| Automated gem update task |