Skip to content

Commit

Permalink
Try caching for workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
adamant-pwn committed May 16, 2024
1 parent d894b6e commit 8d317cb
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,21 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

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

- name: Build Docker image
run: docker build -t build_test .
uses: docker/build-push-action@v4
with:
context: .
load: true
tags: build_test:latest
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Run Docker container
run: docker run --rm build_test -h

0 comments on commit 8d317cb

Please sign in to comment.