chore: cache multiple stages
This commit is contained in:
parent
20cd435743
commit
8b685bca52
16
.github/workflows/docker.yml
vendored
16
.github/workflows/docker.yml
vendored
@ -42,6 +42,22 @@ jobs:
|
||||
tags: ghcr.io/uetchy/uechi.io:latest
|
||||
cache-from: type=local,src=/tmp/.buildx-cache
|
||||
cache-to: type=local,dest=/tmp/.buildx-cache-new
|
||||
|
||||
- name: Cache deps stage
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
target: deps
|
||||
tags: deps_stage
|
||||
cache-from: type=local,src=/tmp/.buildx-cache
|
||||
cache-to: type=local,dest=/tmp/.buildx-cache-new
|
||||
|
||||
- name: Cache build stage
|
||||
uses: docker/build-push-action@v2
|
||||
with:
|
||||
target: build
|
||||
tags: build_stage
|
||||
cache-from: type=local,src=/tmp/.buildx-cache
|
||||
cache-to: type=local,dest=/tmp/.buildx-cache-new
|
||||
|
||||
- name: Image digest
|
||||
run: echo ${{ steps.docker_build.outputs.digest }}
|
||||
|
@ -1,4 +1,4 @@
|
||||
FROM node:15 as build
|
||||
FROM node:15 as deps
|
||||
|
||||
# https://github.com/jgm/pandoc/releases
|
||||
RUN curl -LO https://github.com/jgm/pandoc/releases/download/2.14.0.1/pandoc-2.14.0.1-1-amd64.deb
|
||||
@ -7,6 +7,9 @@ RUN dpkg -i pandoc-2.14.0.1-1-amd64.deb
|
||||
WORKDIR /app
|
||||
COPY package.json /app
|
||||
RUN yarn install
|
||||
|
||||
FROM deps as build
|
||||
|
||||
COPY themes /app/themes
|
||||
COPY source /app/source
|
||||
COPY _config.yml /app/
|
||||
|
Loading…
x
Reference in New Issue
Block a user