Skip to content

Commit 138d49e

Browse files
committed
enable layer caching in github action
1 parent 9a9aad3 commit 138d49e

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

.github/workflows/docker-publish.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@ jobs:
1515
- name: Checkout repository
1616
uses: actions/checkout@v4
1717

18+
- name: Set up Docker Buildx
19+
uses: docker/setup-buildx-action@v3
20+
1821
- name: Log in to the Container registry
1922
uses: docker/login-action@v3
2023
with:
@@ -39,6 +42,9 @@ jobs:
3942
push: true
4043
tags: ${{ steps.meta-api.outputs.tags }}
4144
labels: ${{ steps.meta-api.outputs.labels }}
45+
# using registry cache
46+
cache-from: type=registry,ref=ghcr.io/developmentseed/stac-semantic-search/api:cache
47+
cache-to: type=registry,ref=ghcr.io/developmentseed/stac-semantic-search/api:cache,mode=max
4248

4349
build-and-push-streamlit:
4450
runs-on: ubuntu-latest
@@ -49,6 +55,9 @@ jobs:
4955
- name: Checkout repository
5056
uses: actions/checkout@v4
5157

58+
- name: Set up Docker Buildx
59+
uses: docker/setup-buildx-action@v3
60+
5261
- name: Log in to the Container registry
5362
uses: docker/login-action@v3
5463
with:
@@ -73,3 +82,5 @@ jobs:
7382
push: true
7483
tags: ${{ steps.meta-streamlit.outputs.tags }}
7584
labels: ${{ steps.meta-streamlit.outputs.labels }}
85+
cache-from: type=gha
86+
cache-to: type=gha,mode=max

0 commit comments

Comments
 (0)