diff --git a/static-page-builder/Dockerfile b/static-page-builder/Dockerfile new file mode 100644 index 0000000..0e9ca8c --- /dev/null +++ b/static-page-builder/Dockerfile @@ -0,0 +1,15 @@ +# maybe switch to a stable version of alpine once tidyhtml is avaiblable there +FROM alpine:edge + +# py3-pip is only needed to install j2cli, but python3 and py3-setuptools are +# also needed to run it +RUN apk add --no-cache \ + findutils \ + make \ + py3-pip \ + py3-setuptools \ + python3 \ + sassc \ + tidyhtml && \ + pip install j2cli[yaml] && \ + apk del py3-pip diff --git a/static-page-builder/Makefile b/static-page-builder/Makefile new file mode 100644 index 0000000..2694506 --- /dev/null +++ b/static-page-builder/Makefile @@ -0,0 +1,19 @@ +IMG_NAME=static-page-builder +REGISTRY=registry.monotremata.xyz +IMG=$(REGISTRY)/$(IMG_NAME) +PLATFORMS=linux/amd64,linux/arm64 + +.PHONY: build push buildx + +build: Dockerfile + docker build -t $(IMG) . + +push: build + docker image push $(IMG) + +buildx: Dockerfile + docker buildx build \ + --platform $(PLATFORMS) \ + --tag $(IMG) \ + --push \ + .