mirror of
https://github.com/friendica/docker
synced 2024-06-23 05:29:25 +02:00
switch to packaged gosu
This commit is contained in:
parent
102d52108b
commit
b4509e2785
|
@ -8,46 +8,12 @@ RUN set -ex; \
|
||||||
apt-get install -y --no-install-recommends \
|
apt-get install -y --no-install-recommends \
|
||||||
rsync \
|
rsync \
|
||||||
bzip2 \
|
bzip2 \
|
||||||
|
gosu \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
tini \
|
tini \
|
||||||
;
|
;
|
||||||
|
|
||||||
ENV GOSU_VERSION 1.14
|
|
||||||
RUN set -eux; \
|
|
||||||
# save list of currently installed packages for later so we can clean up
|
|
||||||
savedAptMark="$(apt-mark showmanual)"; \
|
|
||||||
apt-get update; \
|
|
||||||
apt-get install -y --no-install-recommends ca-certificates wget; \
|
|
||||||
if ! command -v gpg; then \
|
|
||||||
apt-get install -y --no-install-recommends gnupg2 dirmngr; \
|
|
||||||
elif gpg --version | grep -q '^gpg (GnuPG) 1\.'; then \
|
|
||||||
# "This package provides support for HKPS keyservers." (GnuPG 1.x only)
|
|
||||||
apt-get install -y --no-install-recommends gnupg-curl; \
|
|
||||||
fi; \
|
|
||||||
rm -rf /var/lib/apt/lists/*; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apt-mark auto '.*' > /dev/null; \
|
|
||||||
[ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \
|
|
||||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
RUN set -ex; \
|
RUN set -ex; \
|
||||||
|
|
|
@ -8,35 +8,10 @@ RUN set -ex; \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
shadow \
|
shadow \
|
||||||
tini;
|
tini; \
|
||||||
|
# gosu currently lives in testing
|
||||||
ENV GOSU_VERSION 1.14
|
apk add --no-cache --repository=https://dl-cdn.alpinelinux.org/alpine/edge/testing/ \
|
||||||
RUN set -eux; \
|
gosu;
|
||||||
\
|
|
||||||
apk add --no-cache --virtual .gosu-deps \
|
|
||||||
ca-certificates \
|
|
||||||
dpkg \
|
|
||||||
gnupg \
|
|
||||||
; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apk del --no-network .gosu-deps; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
|
|
|
@ -8,46 +8,12 @@ RUN set -ex; \
|
||||||
apt-get install -y --no-install-recommends \
|
apt-get install -y --no-install-recommends \
|
||||||
rsync \
|
rsync \
|
||||||
bzip2 \
|
bzip2 \
|
||||||
|
gosu \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
tini \
|
tini \
|
||||||
;
|
;
|
||||||
|
|
||||||
ENV GOSU_VERSION 1.14
|
|
||||||
RUN set -eux; \
|
|
||||||
# save list of currently installed packages for later so we can clean up
|
|
||||||
savedAptMark="$(apt-mark showmanual)"; \
|
|
||||||
apt-get update; \
|
|
||||||
apt-get install -y --no-install-recommends ca-certificates wget; \
|
|
||||||
if ! command -v gpg; then \
|
|
||||||
apt-get install -y --no-install-recommends gnupg2 dirmngr; \
|
|
||||||
elif gpg --version | grep -q '^gpg (GnuPG) 1\.'; then \
|
|
||||||
# "This package provides support for HKPS keyservers." (GnuPG 1.x only)
|
|
||||||
apt-get install -y --no-install-recommends gnupg-curl; \
|
|
||||||
fi; \
|
|
||||||
rm -rf /var/lib/apt/lists/*; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apt-mark auto '.*' > /dev/null; \
|
|
||||||
[ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \
|
|
||||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
RUN set -ex; \
|
RUN set -ex; \
|
||||||
|
|
|
@ -8,46 +8,12 @@ RUN set -ex; \
|
||||||
apt-get install -y --no-install-recommends \
|
apt-get install -y --no-install-recommends \
|
||||||
rsync \
|
rsync \
|
||||||
bzip2 \
|
bzip2 \
|
||||||
|
gosu \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
tini \
|
tini \
|
||||||
;
|
;
|
||||||
|
|
||||||
ENV GOSU_VERSION 1.14
|
|
||||||
RUN set -eux; \
|
|
||||||
# save list of currently installed packages for later so we can clean up
|
|
||||||
savedAptMark="$(apt-mark showmanual)"; \
|
|
||||||
apt-get update; \
|
|
||||||
apt-get install -y --no-install-recommends ca-certificates wget; \
|
|
||||||
if ! command -v gpg; then \
|
|
||||||
apt-get install -y --no-install-recommends gnupg2 dirmngr; \
|
|
||||||
elif gpg --version | grep -q '^gpg (GnuPG) 1\.'; then \
|
|
||||||
# "This package provides support for HKPS keyservers." (GnuPG 1.x only)
|
|
||||||
apt-get install -y --no-install-recommends gnupg-curl; \
|
|
||||||
fi; \
|
|
||||||
rm -rf /var/lib/apt/lists/*; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apt-mark auto '.*' > /dev/null; \
|
|
||||||
[ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \
|
|
||||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
RUN set -ex; \
|
RUN set -ex; \
|
||||||
|
|
|
@ -8,35 +8,10 @@ RUN set -ex; \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
shadow \
|
shadow \
|
||||||
tini;
|
tini; \
|
||||||
|
# gosu currently lives in testing
|
||||||
ENV GOSU_VERSION 1.14
|
apk add --no-cache --repository=https://dl-cdn.alpinelinux.org/alpine/edge/testing/ \
|
||||||
RUN set -eux; \
|
gosu;
|
||||||
\
|
|
||||||
apk add --no-cache --virtual .gosu-deps \
|
|
||||||
ca-certificates \
|
|
||||||
dpkg \
|
|
||||||
gnupg \
|
|
||||||
; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apk del --no-network .gosu-deps; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
|
|
|
@ -8,46 +8,12 @@ RUN set -ex; \
|
||||||
apt-get install -y --no-install-recommends \
|
apt-get install -y --no-install-recommends \
|
||||||
rsync \
|
rsync \
|
||||||
bzip2 \
|
bzip2 \
|
||||||
|
gosu \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
tini \
|
tini \
|
||||||
;
|
;
|
||||||
|
|
||||||
ENV GOSU_VERSION 1.14
|
|
||||||
RUN set -eux; \
|
|
||||||
# save list of currently installed packages for later so we can clean up
|
|
||||||
savedAptMark="$(apt-mark showmanual)"; \
|
|
||||||
apt-get update; \
|
|
||||||
apt-get install -y --no-install-recommends ca-certificates wget; \
|
|
||||||
if ! command -v gpg; then \
|
|
||||||
apt-get install -y --no-install-recommends gnupg2 dirmngr; \
|
|
||||||
elif gpg --version | grep -q '^gpg (GnuPG) 1\.'; then \
|
|
||||||
# "This package provides support for HKPS keyservers." (GnuPG 1.x only)
|
|
||||||
apt-get install -y --no-install-recommends gnupg-curl; \
|
|
||||||
fi; \
|
|
||||||
rm -rf /var/lib/apt/lists/*; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apt-mark auto '.*' > /dev/null; \
|
|
||||||
[ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \
|
|
||||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
RUN set -ex; \
|
RUN set -ex; \
|
||||||
|
|
|
@ -8,46 +8,12 @@ RUN set -ex; \
|
||||||
apt-get install -y --no-install-recommends \
|
apt-get install -y --no-install-recommends \
|
||||||
rsync \
|
rsync \
|
||||||
bzip2 \
|
bzip2 \
|
||||||
|
gosu \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
tini \
|
tini \
|
||||||
;
|
;
|
||||||
|
|
||||||
ENV GOSU_VERSION 1.14
|
|
||||||
RUN set -eux; \
|
|
||||||
# save list of currently installed packages for later so we can clean up
|
|
||||||
savedAptMark="$(apt-mark showmanual)"; \
|
|
||||||
apt-get update; \
|
|
||||||
apt-get install -y --no-install-recommends ca-certificates wget; \
|
|
||||||
if ! command -v gpg; then \
|
|
||||||
apt-get install -y --no-install-recommends gnupg2 dirmngr; \
|
|
||||||
elif gpg --version | grep -q '^gpg (GnuPG) 1\.'; then \
|
|
||||||
# "This package provides support for HKPS keyservers." (GnuPG 1.x only)
|
|
||||||
apt-get install -y --no-install-recommends gnupg-curl; \
|
|
||||||
fi; \
|
|
||||||
rm -rf /var/lib/apt/lists/*; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apt-mark auto '.*' > /dev/null; \
|
|
||||||
[ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \
|
|
||||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
RUN set -ex; \
|
RUN set -ex; \
|
||||||
|
|
|
@ -8,35 +8,10 @@ RUN set -ex; \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
shadow \
|
shadow \
|
||||||
tini;
|
tini; \
|
||||||
|
# gosu currently lives in testing
|
||||||
ENV GOSU_VERSION 1.14
|
apk add --no-cache --repository=https://dl-cdn.alpinelinux.org/alpine/edge/testing/ \
|
||||||
RUN set -eux; \
|
gosu;
|
||||||
\
|
|
||||||
apk add --no-cache --virtual .gosu-deps \
|
|
||||||
ca-certificates \
|
|
||||||
dpkg \
|
|
||||||
gnupg \
|
|
||||||
; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apk del --no-network .gosu-deps; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
|
|
|
@ -8,46 +8,12 @@ RUN set -ex; \
|
||||||
apt-get install -y --no-install-recommends \
|
apt-get install -y --no-install-recommends \
|
||||||
rsync \
|
rsync \
|
||||||
bzip2 \
|
bzip2 \
|
||||||
|
gosu \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
tini \
|
tini \
|
||||||
;
|
;
|
||||||
|
|
||||||
ENV GOSU_VERSION 1.14
|
|
||||||
RUN set -eux; \
|
|
||||||
# save list of currently installed packages for later so we can clean up
|
|
||||||
savedAptMark="$(apt-mark showmanual)"; \
|
|
||||||
apt-get update; \
|
|
||||||
apt-get install -y --no-install-recommends ca-certificates wget; \
|
|
||||||
if ! command -v gpg; then \
|
|
||||||
apt-get install -y --no-install-recommends gnupg2 dirmngr; \
|
|
||||||
elif gpg --version | grep -q '^gpg (GnuPG) 1\.'; then \
|
|
||||||
# "This package provides support for HKPS keyservers." (GnuPG 1.x only)
|
|
||||||
apt-get install -y --no-install-recommends gnupg-curl; \
|
|
||||||
fi; \
|
|
||||||
rm -rf /var/lib/apt/lists/*; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apt-mark auto '.*' > /dev/null; \
|
|
||||||
[ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \
|
|
||||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
RUN set -ex; \
|
RUN set -ex; \
|
||||||
|
|
|
@ -7,35 +7,10 @@ RUN set -ex; \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
shadow \
|
shadow \
|
||||||
tini;
|
tini; \
|
||||||
|
# gosu currently lives in testing
|
||||||
ENV GOSU_VERSION 1.14
|
apk add --no-cache --repository=https://dl-cdn.alpinelinux.org/alpine/edge/testing/ \
|
||||||
RUN set -eux; \
|
gosu;
|
||||||
\
|
|
||||||
apk add --no-cache --virtual .gosu-deps \
|
|
||||||
ca-certificates \
|
|
||||||
dpkg \
|
|
||||||
gnupg \
|
|
||||||
; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apk del --no-network .gosu-deps; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
|
|
|
@ -7,46 +7,12 @@ RUN set -ex; \
|
||||||
apt-get install -y --no-install-recommends \
|
apt-get install -y --no-install-recommends \
|
||||||
rsync \
|
rsync \
|
||||||
bzip2 \
|
bzip2 \
|
||||||
|
gosu \
|
||||||
# For mail() support
|
# For mail() support
|
||||||
msmtp \
|
msmtp \
|
||||||
tini \
|
tini \
|
||||||
;
|
;
|
||||||
|
|
||||||
ENV GOSU_VERSION 1.14
|
|
||||||
RUN set -eux; \
|
|
||||||
# save list of currently installed packages for later so we can clean up
|
|
||||||
savedAptMark="$(apt-mark showmanual)"; \
|
|
||||||
apt-get update; \
|
|
||||||
apt-get install -y --no-install-recommends ca-certificates wget; \
|
|
||||||
if ! command -v gpg; then \
|
|
||||||
apt-get install -y --no-install-recommends gnupg2 dirmngr; \
|
|
||||||
elif gpg --version | grep -q '^gpg (GnuPG) 1\.'; then \
|
|
||||||
# "This package provides support for HKPS keyservers." (GnuPG 1.x only)
|
|
||||||
apt-get install -y --no-install-recommends gnupg-curl; \
|
|
||||||
fi; \
|
|
||||||
rm -rf /var/lib/apt/lists/*; \
|
|
||||||
\
|
|
||||||
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 /usr/local/bin/gosu.asc "https://github.com/tianon/gosu/releases/download/$GOSU_VERSION/gosu-$dpkgArch.asc"; \
|
|
||||||
\
|
|
||||||
# verify the signature
|
|
||||||
export GNUPGHOME="$(mktemp -d)"; \
|
|
||||||
gpg --batch --keyserver hkps://keys.openpgp.org --recv-keys B42F6819007F00F88E364FD4036A9C25BF357DD4; \
|
|
||||||
gpg --batch --verify /usr/local/bin/gosu.asc /usr/local/bin/gosu; \
|
|
||||||
command -v gpgconf && gpgconf --kill all || :; \
|
|
||||||
rm -rf "$GNUPGHOME" /usr/local/bin/gosu.asc; \
|
|
||||||
\
|
|
||||||
# clean up fetch dependencies
|
|
||||||
apt-mark auto '.*' > /dev/null; \
|
|
||||||
[ -z "$savedAptMark" ] || apt-mark manual $savedAptMark; \
|
|
||||||
apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false; \
|
|
||||||
\
|
|
||||||
chmod +x /usr/local/bin/gosu; \
|
|
||||||
# verify that the binary works
|
|
||||||
gosu --version; \
|
|
||||||
gosu nobody true
|
|
||||||
|
|
||||||
# install the PHP extensions we need
|
# install the PHP extensions we need
|
||||||
# see https://friendi.ca/resources/requirements/
|
# see https://friendi.ca/resources/requirements/
|
||||||
RUN set -ex; \
|
RUN set -ex; \
|
||||||
|
|
Loading…
Reference in a new issue