From a5192c949b152432815ea9c06c31fc0a905df83d Mon Sep 17 00:00:00 2001 From: Tigor Hutasuhut Date: Mon, 13 May 2024 21:19:43 +0700 Subject: [PATCH] docker: build now take advantage of caching for web-build-docker target --- Dockerfile | 1 + Makefile | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/Dockerfile b/Dockerfile index 8d15517..e1767c1 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,6 +3,7 @@ WORKDIR /web COPY package.json package-lock.json ./ RUN npm install COPY Makefile ./ +RUN make web-dependencies COPY views ./views COPY tailwind.config.js ./ RUN make web-build diff --git a/Makefile b/Makefile index 5a848fc..e0cbcfb 100644 --- a/Makefile +++ b/Makefile @@ -79,6 +79,10 @@ web-build: web-dependencies mkdir -p public npx tailwindcss -i views/style.css -o public/style.css +web-build-docker: + mkdir -p public + npx tailwindcss -i views/style.css -o public/style.css + build: web-dependencies build-dependencies prepare go build -o redmage