Skip to content

Commit

Permalink
change image build to github repository
Browse files Browse the repository at this point in the history
  • Loading branch information
sgmdlt committed Nov 2, 2024
1 parent 9aca9b6 commit c028bfb
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,22 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- uses: docker/setup-buildx-action@v2
- uses: docker/setup-buildx-action@v3

- uses: docker/login-action@v2
- name: Log in to GitHub Container Registry
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- uses: docker/build-push-action@v2
- name: Build and push
uses: docker/build-push-action@v6
with:
context: .
push: true
cache-from: hexletcomponents/data-charts-api:latest
cache-from: ghcr.io/${{ github.repository }}:latest
cache-to: type=inline
tags: hexletcomponents/data-charts-api:latest
tags: ghcr.io/${{ github.repository }}:latest

0 comments on commit c028bfb

Please sign in to comment.