2021-10-21 01:25:50 +02:00
|
|
|
# syntax=docker/dockerfile:1.3
|
2021-11-03 03:16:22 +01:00
|
|
|
FROM registry.fedoraproject.org/fedora-minimal:35
|
2020-06-07 06:28:44 +02:00
|
|
|
|
2021-11-16 22:57:47 +01:00
|
|
|
ENV HUGO_VERSION 0.89.3
|
2020-06-07 06:28:44 +02:00
|
|
|
|
|
|
|
ARG BUILD_DATE
|
|
|
|
ARG VCS_REF
|
|
|
|
|
|
|
|
LABEL description="Docker image for building websites with Hugo static site generator."
|
|
|
|
|
|
|
|
LABEL org.label-schema.build-date=$BUILD_DATE \
|
2021-04-21 22:51:57 +02:00
|
|
|
org.label-schema.vcs-url="https://git.dotya.ml/wanderer/docker-fedora-hugo.git" \
|
2020-06-07 06:28:44 +02:00
|
|
|
org.label-schema.vcs-ref=$VCS_REF \
|
|
|
|
org.label-schema.license=GPL-3.0
|
|
|
|
|
|
|
|
ADD https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_Linux-64bit.tar.gz /tmp/hugo.tar.gz
|
|
|
|
|
|
|
|
WORKDIR /tmp/
|
2021-04-21 22:56:00 +02:00
|
|
|
RUN microdnf --refresh upgrade -y && microdnf install -y bsdtar git findutils \
|
2021-07-30 23:00:30 +02:00
|
|
|
--nodocs --setopt install_weak_deps=0 \
|
|
|
|
&& microdnf clean all -y
|
|
|
|
# ignore DL3059
|
2021-04-21 22:56:00 +02:00
|
|
|
RUN bsdtar xfv /tmp/hugo.tar.gz && rm -fv /tmp/hugo.tar.gz README.md LICENSE \
|
2020-06-07 06:28:44 +02:00
|
|
|
&& chmod +x /tmp/hugo \
|
|
|
|
&& mkdir -pv /usr/local/bin \
|
2021-01-14 01:30:21 +01:00
|
|
|
&& mv -v /tmp/hugo /usr/local/bin/ \
|
2021-07-30 23:00:30 +02:00
|
|
|
&& rm -rfv /tmp/* \
|
|
|
|
&& rm -rf /usr/share/zoneinfo/* ; rm -rf /usr/include/* ; \
|
2021-11-03 03:02:42 +01:00
|
|
|
find /. -name "*~" -type f -delete > /dev/null 2>&1 ;\
|
2021-01-14 01:30:21 +01:00
|
|
|
find /usr/share/terminfo/. ! -name "*xterm*" ! -name "*screen*" ! -name "*screen*" -type f -delete
|
2020-06-07 06:28:44 +02:00
|
|
|
WORKDIR /
|