Skip to content

Commit

Permalink
Always use latest github action
Browse files Browse the repository at this point in the history
  • Loading branch information
Silex committed Aug 15, 2024
1 parent 6788c83 commit 2b03806
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
12 changes: 6 additions & 6 deletions .github/actions/build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,16 @@ runs:
using: composite
steps:
- name: Login to ghcr.io
uses: docker/login-action@v3
uses: docker/login-action@master
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ fromJSON(inputs.secrets).GITHUB_TOKEN }}

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
uses: docker/setup-buildx-action@master

- uses: ruby/setup-ruby@v1
- uses: ruby/setup-ruby@master

- name: Setup variables
id: data
Expand All @@ -29,7 +29,7 @@ runs:
echo "ghcr_tags=$(bin/images --json | jq -c '.images[] | select(.version == "${{ inputs.version }}" and .context == "${{ inputs.context }}") | .ghcr_tags_with_repository')" >> $GITHUB_OUTPUT
- name: Build & push image to ghcr.io
uses: docker/build-push-action@v5
uses: docker/build-push-action@master
with:
pull: true
push: ${{ github.ref == 'refs/heads/master' }}
Expand All @@ -39,13 +39,13 @@ runs:
cache-to: type=registry,ref=${{ fromJSON(steps.data.outputs.ghcr_tags)[0] }}-cache,mode=max

- name: Login to Docker Hub
uses: docker/login-action@v3
uses: docker/login-action@master
with:
username: ${{ fromJSON(inputs.secrets).DOCKERHUB_USERNAME }}
password: ${{ fromJSON(inputs.secrets).DOCKERHUB_TOKEN }}

- name: Push image to Docker Hub
uses: docker/build-push-action@v5
uses: docker/build-push-action@master
with:
pull: false
push: ${{ github.ref == 'refs/heads/master' }}
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@main
- name: Build
uses: "./.github/actions/build"
with:
Expand All @@ -30,14 +30,14 @@ jobs:
contexts: ${{ steps.data.outputs.contexts }}
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@main
- name: Build
uses: "./.github/actions/build"
with:
secrets: "${{ toJSON(secrets) }}"
version: "${{ inputs.version }}"
context: "${{ inputs.context }}/ci"
- uses: ruby/setup-ruby@v1
- uses: ruby/setup-ruby@master
- name: Setup variables
id: data
run: |
Expand All @@ -53,7 +53,7 @@ jobs:
context: ${{ fromJSON(needs.ci.outputs.contexts) }}
steps:
- name: checkout
uses: actions/checkout@v4
uses: actions/checkout@main
- name: build
uses: "./.github/actions/build"
with:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ jobs:
excludes: ${{ steps.data.outputs.excludes }}
steps:
- name: Checkout
uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
uses: actions/checkout@main
- uses: ruby/setup-ruby@master
- name: Setup variables
id: data
run: |
Expand Down

0 comments on commit 2b03806

Please sign in to comment.