Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[INFRA] fix hadolint errors #65

Merged
merged 1 commit into from
Mar 4, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 16 additions & 11 deletions src/7.4/src/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,28 +26,34 @@ ENV PHP_CFLAGS="-fstack-protector-strong -fpic -fpie -O2" \

### configure php
# hadolint ignore=DL4006,SC2039,DL3003
# hadolint ignore=DL4006,SC2039,DL3003
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]
RUN set -xe; \
\
chmod 755 /usr/local/bin/docker-entrypoint; \
/usr/local/bin/docker-install-requirements php; \
ln -fs /etc/alternatives/vi /usr/bin/vim; \
mkdir -p /tmp/mhsendmail; \
cd /tmp/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src;
WORKDIR /tmp/mhsendmail
RUN set -xe; \
\
curl -LkSso /usr/local/bin/mhsendmail 'https://github.com/mailhog/mhsendmail/releases/download/v0.2.0/mhsendmail_linux_amd64'&& \
chmod 0755 /usr/local/bin/mhsendmail; \
chmod +x /usr/local/bin/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src; \
cd /usr/src; \
WORKDIR /usr/src
RUN set -xe; \
\
curl -fsSL -o php.tar.xz "$PHP_URL"; \
docker-php-source extract; \
docker-php-source extract;
WORKDIR /usr/src/php
RUN set -xe; \
\
gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \
debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \
if [ ! -d "/usr/include/curl" ]; then \
ln -sT "/usr/include/${debMultiarch}/curl" /usr/local/include/curl; \
fi; \
cd /usr/src/php; \
export \
CFLAGS="$PHP_CFLAGS" \
CPPFLAGS="$PHP_CPPFLAGS" \
Expand Down Expand Up @@ -180,10 +186,9 @@ ARG TOOLBOX_RUNTIME_REQUIREMENTS_EXTRA=""
ARG TOOLBOX_BUILD_REQUIREMENTS=""
ARG TOOLBOX_BUILD_REQUIREMENTS_EXTRA=""

# hadolint ignore=DL4006
RUN set -xe; \
\
/usr/local/bin/docker-install-requirements toolbox; \
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]

RUN /usr/local/bin/docker-install-requirements toolbox; \
curl https://rclone.org/install.sh | bash; \
composer require deployer/deployer; \
composer update; \
Expand Down
27 changes: 16 additions & 11 deletions src/8.0/src/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,28 +26,34 @@ ENV PHP_CFLAGS="-fstack-protector-strong -fpic -fpie -O2" \

### configure php
# hadolint ignore=DL4006,SC2039,DL3003
# hadolint ignore=DL4006,SC2039,DL3003
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]
RUN set -xe; \
\
chmod 755 /usr/local/bin/docker-entrypoint; \
/usr/local/bin/docker-install-requirements php; \
ln -fs /etc/alternatives/vi /usr/bin/vim; \
mkdir -p /tmp/mhsendmail; \
cd /tmp/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src;
WORKDIR /tmp/mhsendmail
RUN set -xe; \
\
curl -LkSso /usr/local/bin/mhsendmail 'https://github.com/mailhog/mhsendmail/releases/download/v0.2.0/mhsendmail_linux_amd64'&& \
chmod 0755 /usr/local/bin/mhsendmail; \
chmod +x /usr/local/bin/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src; \
cd /usr/src; \
WORKDIR /usr/src
RUN set -xe; \
\
curl -fsSL -o php.tar.xz "$PHP_URL"; \
docker-php-source extract; \
docker-php-source extract;
WORKDIR /usr/src/php
RUN set -xe; \
\
gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \
debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \
if [ ! -d "/usr/include/curl" ]; then \
ln -sT "/usr/include/${debMultiarch}/curl" /usr/local/include/curl; \
fi; \
cd /usr/src/php; \
export \
CFLAGS="$PHP_CFLAGS" \
CPPFLAGS="$PHP_CPPFLAGS" \
Expand Down Expand Up @@ -180,10 +186,9 @@ ARG TOOLBOX_RUNTIME_REQUIREMENTS_EXTRA=""
ARG TOOLBOX_BUILD_REQUIREMENTS=""
ARG TOOLBOX_BUILD_REQUIREMENTS_EXTRA=""

# hadolint ignore=DL4006
RUN set -xe; \
\
/usr/local/bin/docker-install-requirements toolbox; \
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]

RUN /usr/local/bin/docker-install-requirements toolbox; \
curl https://rclone.org/install.sh | bash; \
composer require deployer/deployer; \
composer update; \
Expand Down
27 changes: 16 additions & 11 deletions src/8.1/src/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,28 +26,34 @@ ENV PHP_CFLAGS="-fstack-protector-strong -fpic -fpie -O2" \

### configure php
# hadolint ignore=DL4006,SC2039,DL3003
# hadolint ignore=DL4006,SC2039,DL3003
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]
RUN set -xe; \
\
chmod 755 /usr/local/bin/docker-entrypoint; \
/usr/local/bin/docker-install-requirements php; \
ln -fs /etc/alternatives/vi /usr/bin/vim; \
mkdir -p /tmp/mhsendmail; \
cd /tmp/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src;
WORKDIR /tmp/mhsendmail
RUN set -xe; \
\
curl -LkSso /usr/local/bin/mhsendmail 'https://github.com/mailhog/mhsendmail/releases/download/v0.2.0/mhsendmail_linux_amd64'&& \
chmod 0755 /usr/local/bin/mhsendmail; \
chmod +x /usr/local/bin/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src; \
cd /usr/src; \
WORKDIR /usr/src
RUN set -xe; \
\
curl -fsSL -o php.tar.xz "$PHP_URL"; \
docker-php-source extract; \
docker-php-source extract;
WORKDIR /usr/src/php
RUN set -xe; \
\
gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \
debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \
if [ ! -d "/usr/include/curl" ]; then \
ln -sT "/usr/include/${debMultiarch}/curl" /usr/local/include/curl; \
fi; \
cd /usr/src/php; \
export \
CFLAGS="$PHP_CFLAGS" \
CPPFLAGS="$PHP_CPPFLAGS" \
Expand Down Expand Up @@ -180,10 +186,9 @@ ARG TOOLBOX_RUNTIME_REQUIREMENTS_EXTRA=""
ARG TOOLBOX_BUILD_REQUIREMENTS=""
ARG TOOLBOX_BUILD_REQUIREMENTS_EXTRA=""

# hadolint ignore=DL4006
RUN set -xe; \
\
/usr/local/bin/docker-install-requirements toolbox; \
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]

RUN /usr/local/bin/docker-install-requirements toolbox; \
curl https://rclone.org/install.sh | bash; \
composer require deployer/deployer; \
composer update; \
Expand Down
27 changes: 16 additions & 11 deletions src/8.2/src/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,28 +26,34 @@ ENV PHP_CFLAGS="-fstack-protector-strong -fpic -fpie -O2" \

### configure php
# hadolint ignore=DL4006,SC2039,DL3003
# hadolint ignore=DL4006,SC2039,DL3003
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]
RUN set -xe; \
\
chmod 755 /usr/local/bin/docker-entrypoint; \
/usr/local/bin/docker-install-requirements php; \
ln -fs /etc/alternatives/vi /usr/bin/vim; \
mkdir -p /tmp/mhsendmail; \
cd /tmp/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src;
WORKDIR /tmp/mhsendmail
RUN set -xe; \
\
curl -LkSso /usr/local/bin/mhsendmail 'https://github.com/mailhog/mhsendmail/releases/download/v0.2.0/mhsendmail_linux_amd64'&& \
chmod 0755 /usr/local/bin/mhsendmail; \
chmod +x /usr/local/bin/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src; \
cd /usr/src; \
WORKDIR /usr/src
RUN set -xe; \
\
curl -fsSL -o php.tar.xz "$PHP_URL"; \
docker-php-source extract; \
docker-php-source extract;
WORKDIR /usr/src/php
RUN set -xe; \
\
gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \
debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \
if [ ! -d "/usr/include/curl" ]; then \
ln -sT "/usr/include/${debMultiarch}/curl" /usr/local/include/curl; \
fi; \
cd /usr/src/php; \
export \
CFLAGS="$PHP_CFLAGS" \
CPPFLAGS="$PHP_CPPFLAGS" \
Expand Down Expand Up @@ -180,10 +186,9 @@ ARG TOOLBOX_RUNTIME_REQUIREMENTS_EXTRA=""
ARG TOOLBOX_BUILD_REQUIREMENTS=""
ARG TOOLBOX_BUILD_REQUIREMENTS_EXTRA=""

# hadolint ignore=DL4006
RUN set -xe; \
\
/usr/local/bin/docker-install-requirements toolbox; \
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]

RUN /usr/local/bin/docker-install-requirements toolbox; \
curl https://rclone.org/install.sh | bash; \
composer require deployer/deployer; \
composer update; \
Expand Down
30 changes: 17 additions & 13 deletions src/8.3/src/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,28 +26,34 @@ ENV PHP_CFLAGS="-fstack-protector-strong -fpic -fpie -O2" \

### configure php
# hadolint ignore=DL4006,SC2039,DL3003
# hadolint ignore=DL4006,SC2039,DL3003
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]
RUN set -xe; \
\
chmod 755 /usr/local/bin/docker-entrypoint; \
/usr/local/bin/docker-install-requirements php; \
ln -fs /etc/alternatives/vi /usr/bin/vim; \
mkdir -p /tmp/mhsendmail; \
cd /tmp/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src;
WORKDIR /tmp/mhsendmail
RUN set -xe; \
\
curl -LkSso /usr/local/bin/mhsendmail 'https://github.com/mailhog/mhsendmail/releases/download/v0.2.0/mhsendmail_linux_amd64'&& \
chmod 0755 /usr/local/bin/mhsendmail; \
chmod +x /usr/local/bin/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src; \
cd /usr/src; \
WORKDIR /usr/src
RUN set -xe; \
\
curl -fsSL -o php.tar.xz "$PHP_URL"; \
docker-php-source extract; \
docker-php-source extract;
WORKDIR /usr/src/php
RUN set -xe; \
\
gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \
debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \
if [ ! -d "/usr/include/curl" ]; then \
ln -sT "/usr/include/${debMultiarch}/curl" /usr/local/include/curl; \
fi; \
cd /usr/src/php; \
export \
CFLAGS="$PHP_CFLAGS" \
CPPFLAGS="$PHP_CPPFLAGS" \
Expand Down Expand Up @@ -131,8 +137,7 @@ RUN set -xe; \
echo 'pm.min_spare_servers = 2'; \
echo 'pm.max_spare_servers = 5'; \
echo 'pm.status_path = /status'; \
} | tee /usr/local/etc/php-fpm.d/zz-docker.conf; \
/usr/local/bin/docker-layer-clean
} | tee /usr/local/etc/php-fpm.d/zz-docker.conf;

## configure php extensions
# hadolint ignore=DL4006,SC2086,DL3003
Expand Down Expand Up @@ -181,10 +186,9 @@ ARG TOOLBOX_RUNTIME_REQUIREMENTS_EXTRA=""
ARG TOOLBOX_BUILD_REQUIREMENTS=""
ARG TOOLBOX_BUILD_REQUIREMENTS_EXTRA=""

# hadolint ignore=DL4006
RUN set -xe; \
\
/usr/local/bin/docker-install-requirements toolbox; \
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]

RUN /usr/local/bin/docker-install-requirements toolbox; \
curl https://rclone.org/install.sh | bash; \
composer require deployer/deployer; \
composer update; \
Expand Down
27 changes: 16 additions & 11 deletions src/8.4/src/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -26,28 +26,34 @@ ENV PHP_CFLAGS="-fstack-protector-strong -fpic -fpie -O2" \

### configure php
# hadolint ignore=DL4006,SC2039,DL3003
# hadolint ignore=DL4006,SC2039,DL3003
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]
RUN set -xe; \
\
chmod 755 /usr/local/bin/docker-entrypoint; \
/usr/local/bin/docker-install-requirements php; \
ln -fs /etc/alternatives/vi /usr/bin/vim; \
mkdir -p /tmp/mhsendmail; \
cd /tmp/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src;
WORKDIR /tmp/mhsendmail
RUN set -xe; \
\
curl -LkSso /usr/local/bin/mhsendmail 'https://github.com/mailhog/mhsendmail/releases/download/v0.2.0/mhsendmail_linux_amd64'&& \
chmod 0755 /usr/local/bin/mhsendmail; \
chmod +x /usr/local/bin/mhsendmail; \
mkdir -p "${PHP_INI_DIR}/conf.d"; \
mkdir -p /usr/src; \
cd /usr/src; \
WORKDIR /usr/src
RUN set -xe; \
\
curl -fsSL -o php.tar.xz "$PHP_URL"; \
docker-php-source extract; \
docker-php-source extract;
WORKDIR /usr/src/php
RUN set -xe; \
\
gnuArch="$(dpkg-architecture --query DEB_BUILD_GNU_TYPE)"; \
debMultiarch="$(dpkg-architecture --query DEB_BUILD_MULTIARCH)"; \
if [ ! -d "/usr/include/curl" ]; then \
ln -sT "/usr/include/${debMultiarch}/curl" /usr/local/include/curl; \
fi; \
cd /usr/src/php; \
export \
CFLAGS="$PHP_CFLAGS" \
CPPFLAGS="$PHP_CPPFLAGS" \
Expand Down Expand Up @@ -180,10 +186,9 @@ ARG TOOLBOX_RUNTIME_REQUIREMENTS_EXTRA=""
ARG TOOLBOX_BUILD_REQUIREMENTS=""
ARG TOOLBOX_BUILD_REQUIREMENTS_EXTRA=""

# hadolint ignore=DL4006
RUN set -xe; \
\
/usr/local/bin/docker-install-requirements toolbox; \
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]

RUN /usr/local/bin/docker-install-requirements toolbox; \
curl https://rclone.org/install.sh | bash; \
composer require deployer/deployer; \
composer update; \
Expand Down