Skip to content

Instantly share code, notes, and snippets.

@rodgert
Created March 26, 2018 15:42
Show Gist options
  • Save rodgert/a84eeca9d03006243272e48dbd764765 to your computer and use it in GitHub Desktop.
Save rodgert/a84eeca9d03006243272e48dbd764765 to your computer and use it in GitHub Desktop.
f27 with perms fixup
FROM fedora
RUN dnf groupinstall -y "C Development Tools and Libraries"
RUN dnf install -y cmake ninja-build
RUN dnf install -y wget dpkg gpg
ENV GOSU_VERSION 1.10
RUN set -ex; \
#download gosu
dpkgArch="$(dpkg --print-architecture | awk -F- '{ print $NF }')"; \
wget -O /usr/local/bin/gosu "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch"; \
wget -O /tmp/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
# verify signature
export GNUPGHOME="$(mktemp -d)"; \
gpg --keyserver ha.pool.sks-keyservers.net --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
gpg --batch --verify /tmp/gosu.asc /usr/local/bin/gosu; \
rm -r "$GNUPGHOME" /tmp/gosu.asc; \
chmod +x /usr/local/bin/gosu; \
# verify gosu works
gosu nobody true; \
dnf -y remove wget dpkg gpg; \
dnf clean all
COPY entrypoint.sh /usr/local/bin/entrypoint.sh
RUN chmod u+x /usr/local/bin/entrypoint.sh
ENTRYPOINT ["/usr/local/bin/entrypoint.sh"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment