chore(deps): update actions/checkout action to v5 (#113) #127
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: CI | |
| on: | |
| push: | |
| branches: | |
| - main | |
| workflow_dispatch: | |
| inputs: | |
| version: | |
| description: Package version (e.g. v0.1.0) | |
| required: false | |
| env: | |
| UP_API_TOKEN: ${{ secrets.UP_API_TOKEN }} | |
| UP_ROBOT_ID: ${{ secrets.UP_ROBOT_ID }} | |
| UP_ORG: ${{ secrets.UP_ORG }} | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| id: checkout | |
| uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5 | |
| - name: Install and login with up | |
| if: env.UP_API_TOKEN != '' && env.UP_ORG != '' | |
| uses: upbound/action-up@53fe6395637d884c80d2bbc8c2d75d0ece776ced # v1 | |
| with: | |
| api-token: ${{ secrets.UP_API_TOKEN }} | |
| organization: ${{ secrets.UP_ORG }} | |
| # doesn't work with plain token when pushing otherwise | |
| - name: Login to xpkg with robot | |
| uses: docker/login-action@5e57cd118135c172c3672efd75eb46360885c0ef # v3 | |
| with: | |
| registry: xpkg.upbound.io | |
| username: ${{ env.UP_ROBOT_ID }} | |
| password: ${{ env.UP_API_TOKEN }} | |
| - name: Build and Push Upbound project | |
| if: env.UP_API_TOKEN != '' | |
| uses: upbound/action-up-project@b849ec1eb303ae4abf22b2b86c0e2afca155137b # v1 | |
| with: | |
| push-project: true | |
| tag: ${{ inputs.version || '' }} | |
| # login-check does `up org list` which doesn't work with a robot-token | |
| skip-login-check: true |