docker: build now take advantage of caching for web-build-docker target

This commit is contained in:
Tigor Hutasuhut 2024-05-13 21:19:43 +07:00
parent 7488e2b5e3
commit a5192c949b
2 changed files with 5 additions and 0 deletions

View file

@ -3,6 +3,7 @@ WORKDIR /web
COPY package.json package-lock.json ./ COPY package.json package-lock.json ./
RUN npm install RUN npm install
COPY Makefile ./ COPY Makefile ./
RUN make web-dependencies
COPY views ./views COPY views ./views
COPY tailwind.config.js ./ COPY tailwind.config.js ./
RUN make web-build RUN make web-build

View file

@ -79,6 +79,10 @@ web-build: web-dependencies
mkdir -p public mkdir -p public
npx tailwindcss -i views/style.css -o public/style.css 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 build: web-dependencies build-dependencies prepare
go build -o redmage go build -o redmage