This commit is contained in:
Dominic Grimm 2023-05-17 21:37:01 +02:00
commit 5dedbcb739
Signed by: dergrimm
GPG key ID: B6FFE500AAD54A3A
2 changed files with 16 additions and 0 deletions

10
Dockerfile Normal file
View file

@ -0,0 +1,10 @@
FROM docker.io/golang:1.20.4-alpine3.18 as builder
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]
WORKDIR /usr/src
ARG VERSION
RUN wget -qO- https://github.com/tdewolff/minify/archive/refs/tags/v${VERSION}.tar.gz | tar xzf -
WORKDIR /usr/src/minify-${VERSION}
RUN go install ./cmd/minify
FROM docker.io/alpine:3.18.0
COPY --from=builder /go/bin/minify /usr/local/bin

6
Makefile Normal file
View file

@ -0,0 +1,6 @@
.PHONY: build
VERSION = "2.12.5"
build:
docker build . --build-arg="VERSION=$(VERSION)" -t git.dergrimm.net/dergrimm/minify:$(VERSION) --progress=plain