UNCLASSIFIED

Commit adf529a6 authored by Omar Hasan's avatar Omar Hasan Committed by sean.melissari
Browse files

Fix UBI minimal

parent bd0c2b5a
...@@ -2,6 +2,7 @@ ARG BASE_REGISTRY=registry1.dsop.io ...@@ -2,6 +2,7 @@ ARG BASE_REGISTRY=registry1.dsop.io
ARG BASE_IMAGE=ironbank/redhat/ubi/ubi8-minimal ARG BASE_IMAGE=ironbank/redhat/ubi/ubi8-minimal
ARG BASE_TAG=8.2 ARG BASE_TAG=8.2
FROM ${BASE_REGISTRY}/${BASE_IMAGE}:${BASE_TAG} FROM ${BASE_REGISTRY}/${BASE_IMAGE}:${BASE_TAG}
LABEL \ LABEL \
org.opencontainers.image.title="hugo" \ org.opencontainers.image.title="hugo" \
...@@ -12,11 +13,14 @@ LABEL \ ...@@ -12,11 +13,14 @@ LABEL \
COPY hugo_0.76.4_Linux-64bit.tar.gz hugo.tar.gz COPY hugo_0.76.4_Linux-64bit.tar.gz hugo.tar.gz
RUN groupadd -r hugo && \ RUN microdnf -y install shadow-utils tar gzip --setopt=tsflags=nodocs && \
groupadd -r hugo && \
useradd -m -r hugo -g hugo && \ useradd -m -r hugo -g hugo && \
tar -xzf hugo.tar.gz hugo && \ tar -xzf hugo.tar.gz hugo && \
install -m 755 hugo /usr/bin && \ install -m 755 hugo /usr/bin && \
rm -rf hugo.tar.gz rm -rf hugo.tar.gz && \
microdnf -y remove shadow-utils tar gzip && \
microdnf clean all
USER hugo USER hugo
WORKDIR /home/hugo WORKDIR /home/hugo
...@@ -24,4 +28,3 @@ WORKDIR /home/hugo ...@@ -24,4 +28,3 @@ WORKDIR /home/hugo
EXPOSE 1313 EXPOSE 1313
ENTRYPOINT ["hugo"] ENTRYPOINT ["hugo"]
CMD ["--bind", "0.0.0.0"]
...@@ -16,5 +16,5 @@ Once the site is created and you are in the top level of the `quickstart` ...@@ -16,5 +16,5 @@ Once the site is created and you are in the top level of the `quickstart`
directory you serve the site like so: directory you serve the site like so:
``` ```
docker run --rm -it -v $PWD:/home/hugo -p 1313:1313 registry1.dsop.io/ironbank/opensource/hugo:0.76.4 server docker run --rm -it -v $PWD:/home/hugo -p 1313:1313 registry1.dsop.io/ironbank/opensource/hugo:0.76.4 server --bind 0.0.0.0
``` ```
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment