2022-06-20 00:03:28 +00:00
|
|
|
FROM thegeeklab/alpine:latest@sha256:799f39383e4a2a83aa751bf97a7cbbbc7f4855e1b5df6b1bb73b72122295e5c6
|
2021-05-06 20:31:39 +00:00
|
|
|
|
|
|
|
LABEL maintainer="Robert Kaussow <mail@thegeeklab.de>"
|
|
|
|
LABEL org.opencontainers.image.authors="Robert Kaussow <mail@thegeeklab.de>"
|
|
|
|
LABEL org.opencontainers.image.title="Hugo static site generator"
|
|
|
|
LABEL org.opencontainers.image.url="https://gitea.rknet.org/docker/hugo"
|
|
|
|
LABEL org.opencontainers.image.source="https://gitea.rknet.org/docker/hugo"
|
|
|
|
LABEL org.opencontainers.image.documentation="https://gitea.rknet.org/docker/hugo"
|
|
|
|
|
|
|
|
ARG BUILD_VERSION
|
|
|
|
|
|
|
|
# renovate: datasource=github-releases depName=gohugoio/hugo
|
2022-06-20 19:31:48 +00:00
|
|
|
ENV HUGO_VERSION="${BUILD_VERSION:-v0.101.0}"
|
2021-05-06 20:31:39 +00:00
|
|
|
|
2021-05-06 20:40:23 +00:00
|
|
|
ENV HUGO_ENV=production
|
|
|
|
|
2021-05-06 20:31:39 +00:00
|
|
|
COPY overlay/ /
|
|
|
|
|
|
|
|
RUN apk add --update --no-cache --virtual .build-deps tar curl && \
|
2022-04-20 21:22:15 +00:00
|
|
|
apk add --update --no-cache libc6-compat libstdc++ busybox-suid bash bash-completion git tzdata make asciidoctor && \
|
2021-05-06 20:31:39 +00:00
|
|
|
echo "Installing hugo version '${HUGO_VERSION##v}' ..." && \
|
2022-06-21 13:15:18 +00:00
|
|
|
curl -SsfL "https://github.com/gohugoio/hugo/releases/download/${HUGO_VERSION}/hugo_extended_${HUGO_VERSION##v}_Linux-64bit.tar.gz" | \
|
2021-05-06 20:31:39 +00:00
|
|
|
tar xz -C /usr/local/bin hugo && \
|
|
|
|
chmod 755 /usr/local/bin/hugo && \
|
|
|
|
ln -s /usr/local/bin/hugo /usr/local/bin/hugo-official && \
|
|
|
|
apk del .build-deps && \
|
|
|
|
rm -rf /var/cache/apk/* && \
|
|
|
|
rm -rf /tmp/* && \
|
|
|
|
rm -rf /root/.cache/
|
|
|
|
|
|
|
|
USER root
|
|
|
|
CMD ["help"]
|
|
|
|
ENTRYPOINT ["/usr/local/bin/hugo"]
|