Skip to content

Commit

Permalink
Fix install errors
Browse files Browse the repository at this point in the history
  • Loading branch information
cytopia committed Apr 4, 2022
1 parent e02e778 commit a425b5f
Show file tree
Hide file tree
Showing 16 changed files with 704 additions and 488 deletions.
4 changes: 2 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
## Release 0.139

#### Added
- Added mongodb command line client
- Added postgresql command line client for PHP 7.1+
- (Re-)added mongodb command line client
- (Re-)added postgresql command line client

### Changed
- Speed up `xargs` commands by using multi-CPU
Expand Down
73 changes: 40 additions & 33 deletions Dockerfiles/work/Dockerfile-5.2
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,6 @@ RUN set -eux \
&& echo "deb http://archive.debian.org/debian jessie-backports main" > /etc/apt/sources.list.d/backports.list \
&& curl -sS -L --fail "https://packages.blackfire.io/gpg.key" | APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1 apt-key add - \
&& echo "deb http://packages.blackfire.io/debian any main" > /etc/apt/sources.list.d/blackfire.list \
&& curl -sS -k -L --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc | APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1 apt-key add - \
&& echo "deb https://apt-archive.postgresql.org/pub/repos/apt/ jessie-pgdg main" > /etc/apt/sources.list.d/pgsql.list \
\
&& DEBIAN_FRONTEND=noninteractive apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends --no-install-suggests \
Expand Down Expand Up @@ -100,20 +98,6 @@ RUN set -eux \
\
mysql-client \
\
# 5.2: mongodb-clients (amd64)
# 5.3: mongodb-clients (amd64)
# 5.4: mongodb-clients (amd64)
# 5.5: mongodb-clients (amd64)
# 5.6: mongodb-clients (amd64, arm64)
# 7.0: mongodb-clients (amd64, arm64)
# 7.1: mongo-tools OR mongodb-org-(tools|shell) (amd64, arm64)
# 7.2: mongo-tools OR mongodb-org-(tools|shell) (amd64, arm64)
# 7.3: mongodb-org-(tools|shell) (amd64, arm64)
# 7.4: mongodb-org-(tools|shell) (amd64, arm64)
# 8.0: mongodb-org-(tools|shell) (amd64, arm64)
# 8.1: mongodb-org-(tools|shell) (amd64, arm64)
# 8.2: mongodb-org-(tools|shell) (amd64, arm64)
$( if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then echo 'mongodb-clients'; fi ) \
mupdf \
mupdf-tools \
nano \
Expand All @@ -122,9 +106,6 @@ RUN set -eux \
openssh-client \
patch \
patchelf \
\
postgresql-client \
\
redis-tools \
rsync \
rubygems \
Expand All @@ -149,20 +130,7 @@ RUN set -eux \
\
&& (find /usr/local/bin -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true) \
&& (find /usr/local/lib -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true) \
&& (find /usr/local/sbin -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true) \
\
# Check version: mongofiles
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
mongofiles --version; \
fi \
\
# Check version: pg_isready
&& pg_isready --version \
\
# Check version: mysql
&& mysql --version \
\
&& true
&& (find /usr/local/sbin -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true)


###
Expand Down Expand Up @@ -205,6 +173,29 @@ RUN set -eux \
&& su -c '. /opt/nvm/nvm.sh; corepack enable' devilbox \
\
\
# -------------------- pgsql_client --------------------
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
curl -sS -k -L --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc | APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1 apt-key add - \
&& echo "deb https://apt-archive.postgresql.org/pub/repos/apt/ jessie-pgdg main" > /etc/apt/sources.list.d/pgsql.list \
&& apt-get update; \
fi \
\
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
apt-get install -y --no-install-recommends --no-install-suggests \
postgresql-client; \
fi \
\
&& rm -rf /var/lib/apt/lists/* \
\
# -------------------- mongo_client --------------------
&& apt-get update \
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
apt-get install -y --no-install-recommends --no-install-suggests \
mongodb-clients; \
fi \
\
&& rm -rf /var/lib/apt/lists/* \
\
# -------------------- awesomeci --------------------
&& git clone https://github.com/cytopia/awesome-ci.git /usr/local/src/awesome-ci \
&& cd /usr/local/src/awesome-ci \
Expand Down Expand Up @@ -629,6 +620,22 @@ RUN set -eux \
# -------------------- Software --------------------
&& su -c '. /opt/nvm/nvm.sh; nvm --version' devilbox | grep -E '^v?[0-9][.0-9]+' \
&& su -c '. /opt/nvm/nvm.sh; yarn --version' devilbox | grep -E '^v?[0-9][.0-9]+' \
\
&& if echo '5.2' | grep -E '^(5.2|5.3|5.4|5.5|5.6|7.0)$' >/dev/null; then \
if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
pg_isready --version; \
fi \
else \
pg_isready --version; \
fi \
\
&& if echo '5.2' | grep -E '^(5.2|5.3|5.4|5.5)$' >/dev/null; then \
if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
mongofiles --version; \
fi \
else \
mongofiles --version; \
fi \
\
&& regex-grep --version | grep -E '[0-9][.0-9]+' \
&& git-flow version | grep -E '[0-9][.0-9]+' \
Expand Down
73 changes: 40 additions & 33 deletions Dockerfiles/work/Dockerfile-5.3
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,6 @@ RUN set -eux \
&& echo "deb http://archive.debian.org/debian jessie-backports main" > /etc/apt/sources.list.d/backports.list \
&& curl -sS -L --fail "https://packages.blackfire.io/gpg.key" | APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1 apt-key add - \
&& echo "deb http://packages.blackfire.io/debian any main" > /etc/apt/sources.list.d/blackfire.list \
&& curl -sS -k -L --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc | APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1 apt-key add - \
&& echo "deb https://apt-archive.postgresql.org/pub/repos/apt/ jessie-pgdg main" > /etc/apt/sources.list.d/pgsql.list \
\
&& DEBIAN_FRONTEND=noninteractive apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends --no-install-suggests \
Expand Down Expand Up @@ -100,20 +98,6 @@ RUN set -eux \
\
mysql-client \
\
# 5.2: mongodb-clients (amd64)
# 5.3: mongodb-clients (amd64)
# 5.4: mongodb-clients (amd64)
# 5.5: mongodb-clients (amd64)
# 5.6: mongodb-clients (amd64, arm64)
# 7.0: mongodb-clients (amd64, arm64)
# 7.1: mongo-tools OR mongodb-org-(tools|shell) (amd64, arm64)
# 7.2: mongo-tools OR mongodb-org-(tools|shell) (amd64, arm64)
# 7.3: mongodb-org-(tools|shell) (amd64, arm64)
# 7.4: mongodb-org-(tools|shell) (amd64, arm64)
# 8.0: mongodb-org-(tools|shell) (amd64, arm64)
# 8.1: mongodb-org-(tools|shell) (amd64, arm64)
# 8.2: mongodb-org-(tools|shell) (amd64, arm64)
$( if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then echo 'mongodb-clients'; fi ) \
mupdf \
mupdf-tools \
nano \
Expand All @@ -122,9 +106,6 @@ RUN set -eux \
openssh-client \
patch \
patchelf \
\
postgresql-client \
\
redis-tools \
rsync \
rubygems \
Expand All @@ -149,20 +130,7 @@ RUN set -eux \
\
&& (find /usr/local/bin -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true) \
&& (find /usr/local/lib -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true) \
&& (find /usr/local/sbin -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true) \
\
# Check version: mongofiles
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
mongofiles --version; \
fi \
\
# Check version: pg_isready
&& pg_isready --version \
\
# Check version: mysql
&& mysql --version \
\
&& true
&& (find /usr/local/sbin -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true)


###
Expand Down Expand Up @@ -217,6 +185,29 @@ RUN set -eux \
&& su -c '. /opt/nvm/nvm.sh; corepack enable' devilbox \
\
\
# -------------------- pgsql_client --------------------
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
curl -sS -k -L --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc | APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1 apt-key add - \
&& echo "deb https://apt-archive.postgresql.org/pub/repos/apt/ jessie-pgdg main" > /etc/apt/sources.list.d/pgsql.list \
&& apt-get update; \
fi \
\
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
apt-get install -y --no-install-recommends --no-install-suggests \
postgresql-client; \
fi \
\
&& rm -rf /var/lib/apt/lists/* \
\
# -------------------- mongo_client --------------------
&& apt-get update \
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
apt-get install -y --no-install-recommends --no-install-suggests \
mongodb-clients; \
fi \
\
&& rm -rf /var/lib/apt/lists/* \
\
# -------------------- awesomeci --------------------
&& git clone https://github.com/cytopia/awesome-ci.git /usr/local/src/awesome-ci \
&& cd /usr/local/src/awesome-ci \
Expand Down Expand Up @@ -691,6 +682,22 @@ RUN set -eux \
&& composer --version 2>/dev/null | grep -Ei '(composer|version)\s*[0-9][.0-9]+' \
&& su -c '. /opt/nvm/nvm.sh; nvm --version' devilbox | grep -E '^v?[0-9][.0-9]+' \
&& su -c '. /opt/nvm/nvm.sh; yarn --version' devilbox | grep -E '^v?[0-9][.0-9]+' \
\
&& if echo '5.3' | grep -E '^(5.2|5.3|5.4|5.5|5.6|7.0)$' >/dev/null; then \
if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
pg_isready --version; \
fi \
else \
pg_isready --version; \
fi \
\
&& if echo '5.3' | grep -E '^(5.2|5.3|5.4|5.5)$' >/dev/null; then \
if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
mongofiles --version; \
fi \
else \
mongofiles --version; \
fi \
\
&& regex-grep --version | grep -E '[0-9][.0-9]+' \
&& drush7 --version | grep -E '7[.0-9]+\s*$' \
Expand Down
73 changes: 40 additions & 33 deletions Dockerfiles/work/Dockerfile-5.4
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,6 @@ RUN set -eux \
&& echo "deb http://archive.debian.org/debian jessie-backports main" > /etc/apt/sources.list.d/backports.list \
&& curl -sS -L --fail "https://packages.blackfire.io/gpg.key" | APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1 apt-key add - \
&& echo "deb http://packages.blackfire.io/debian any main" > /etc/apt/sources.list.d/blackfire.list \
&& curl -sS -k -L --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc | APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1 apt-key add - \
&& echo "deb https://apt-archive.postgresql.org/pub/repos/apt/ jessie-pgdg main" > /etc/apt/sources.list.d/pgsql.list \
\
&& DEBIAN_FRONTEND=noninteractive apt-get update \
&& DEBIAN_FRONTEND=noninteractive apt-get install -y --no-install-recommends --no-install-suggests \
Expand Down Expand Up @@ -100,20 +98,6 @@ RUN set -eux \
\
mysql-client \
\
# 5.2: mongodb-clients (amd64)
# 5.3: mongodb-clients (amd64)
# 5.4: mongodb-clients (amd64)
# 5.5: mongodb-clients (amd64)
# 5.6: mongodb-clients (amd64, arm64)
# 7.0: mongodb-clients (amd64, arm64)
# 7.1: mongo-tools OR mongodb-org-(tools|shell) (amd64, arm64)
# 7.2: mongo-tools OR mongodb-org-(tools|shell) (amd64, arm64)
# 7.3: mongodb-org-(tools|shell) (amd64, arm64)
# 7.4: mongodb-org-(tools|shell) (amd64, arm64)
# 8.0: mongodb-org-(tools|shell) (amd64, arm64)
# 8.1: mongodb-org-(tools|shell) (amd64, arm64)
# 8.2: mongodb-org-(tools|shell) (amd64, arm64)
$( if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then echo 'mongodb-clients'; fi ) \
mupdf \
mupdf-tools \
nano \
Expand All @@ -122,9 +106,6 @@ RUN set -eux \
openssh-client \
patch \
patchelf \
\
postgresql-client \
\
redis-tools \
rsync \
rubygems \
Expand All @@ -149,20 +130,7 @@ RUN set -eux \
\
&& (find /usr/local/bin -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true) \
&& (find /usr/local/lib -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true) \
&& (find /usr/local/sbin -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true) \
\
# Check version: mongofiles
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
mongofiles --version; \
fi \
\
# Check version: pg_isready
&& pg_isready --version \
\
# Check version: mysql
&& mysql --version \
\
&& true
&& (find /usr/local/sbin -type f -print0 | xargs -n1 -0 -P$(getconf _NPROCESSORS_ONLN) strip --strip-all -p 2>/dev/null || true)


###
Expand Down Expand Up @@ -217,6 +185,29 @@ RUN set -eux \
&& su -c '. /opt/nvm/nvm.sh; corepack enable' devilbox \
\
\
# -------------------- pgsql_client --------------------
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
curl -sS -k -L --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc | APT_KEY_DONT_WARN_ON_DANGEROUS_USAGE=1 apt-key add - \
&& echo "deb https://apt-archive.postgresql.org/pub/repos/apt/ jessie-pgdg main" > /etc/apt/sources.list.d/pgsql.list \
&& apt-get update; \
fi \
\
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
apt-get install -y --no-install-recommends --no-install-suggests \
postgresql-client; \
fi \
\
&& rm -rf /var/lib/apt/lists/* \
\
# -------------------- mongo_client --------------------
&& apt-get update \
&& if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
apt-get install -y --no-install-recommends --no-install-suggests \
mongodb-clients; \
fi \
\
&& rm -rf /var/lib/apt/lists/* \
\
# -------------------- awesomeci --------------------
&& git clone https://github.com/cytopia/awesome-ci.git /usr/local/src/awesome-ci \
&& cd /usr/local/src/awesome-ci \
Expand Down Expand Up @@ -729,6 +720,22 @@ RUN set -eux \
&& composer --version 2>/dev/null | grep -Ei '(composer|version)\s*[0-9][.0-9]+' \
&& su -c '. /opt/nvm/nvm.sh; nvm --version' devilbox | grep -E '^v?[0-9][.0-9]+' \
&& su -c '. /opt/nvm/nvm.sh; yarn --version' devilbox | grep -E '^v?[0-9][.0-9]+' \
\
&& if echo '5.4' | grep -E '^(5.2|5.3|5.4|5.5|5.6|7.0)$' >/dev/null; then \
if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
pg_isready --version; \
fi \
else \
pg_isready --version; \
fi \
\
&& if echo '5.4' | grep -E '^(5.2|5.3|5.4|5.5)$' >/dev/null; then \
if [ "$(dpkg-architecture --query DEB_BUILD_ARCH)" = "amd64" ]; then \
mongofiles --version; \
fi \
else \
mongofiles --version; \
fi \
\
&& regex-grep --version | grep -E '[0-9][.0-9]+' \
&& dep --version 2>/dev/null | grep -Ei 'deployer\s*(version\s*)?[0-9][.0-9]+' \
Expand Down
Loading

0 comments on commit a425b5f

Please sign in to comment.