From f75b8a90e8d1960a937fdce251200f91ca7e1eb3 Mon Sep 17 00:00:00 2001 From: Alan Nelson <alan.nelson@nebraska.edu> Date: Mon, 6 Mar 2023 16:59:56 -0600 Subject: [PATCH 1/6] Bump android build image to JDK 11 --- android-build-server/Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/android-build-server/Dockerfile b/android-build-server/Dockerfile index 148f105..3bda569 100644 --- a/android-build-server/Dockerfile +++ b/android-build-server/Dockerfile @@ -1,4 +1,4 @@ -FROM adoptopenjdk/openjdk8:alpine +FROM adoptopenjdk/openjdk11:alpine ARG BUILD_DATE ARG VCS_REF @@ -29,4 +29,4 @@ COPY entrypoint.sh /usr/local/bin/ RUN chmod +x /usr/local/bin/entrypoint.sh ENTRYPOINT ["/usr/local/bin/entrypoint.sh"] -CMD "/bin/bash" \ No newline at end of file +CMD "/bin/bash" -- GitLab From 3da95c4b62279f91e6666f6cc9760c90b394e602 Mon Sep 17 00:00:00 2001 From: Alan Nelson <alan.nelson@nebraska.edu> Date: Mon, 6 Mar 2023 17:13:38 -0600 Subject: [PATCH 2/6] Update Android build image --- android-build-server/Dockerfile | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/android-build-server/Dockerfile b/android-build-server/Dockerfile index 3bda569..ad72627 100644 --- a/android-build-server/Dockerfile +++ b/android-build-server/Dockerfile @@ -8,22 +8,22 @@ LABEL org.label-schema.build-date=$BUILD_DATE \ org.label-schema.description="Docker image for building Android projects" \ org.label-schema.vcs-ref=$VCS_REF \ org.label-schema.vendor="University of Nebraska - Lincoln" \ - org.label-schema.version="0.1.0" \ + org.label-schema.version="0.2.0" \ org.label-schema.schema-version="1.0" \ maintainer="Alan Nelson <alan.nelson@nebraska.edu>" -ENV ANDROID_SDK_VERSION 4333796 ENV ANDROID_HOME /opt/android-sdk-linux -ENV PATH ${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/tools/bin:${ANDROID_HOME}/platform-tools +ENV PATH ${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/tools/bin:${ANDROID_HOME}/platform-tools:${ANDROID_HOME}/cmdline-tools/bin WORKDIR /opt RUN apk add --no-cache curl bash unzip libstdc++ su-exec RUN mkdir -p /opt/android-sdk-linux \ - && curl -q -o android-sdk-tools.zip -L https://dl.google.com/android/repository/sdk-tools-linux-${ANDROID_SDK_VERSION}.zip \ - && unzip -q android-sdk-tools.zip -d ${ANDROID_HOME} \ - && rm -f android-sdk-tools.zip \ - && yes | sdkmanager --licenses + && curl -q -o commandlinetools.zip -L https://dl.google.com/android/repository/commandlinetools-linux-9477386_latest.zip \ + && unzip -q commandlinetools.zip -d ${ANDROID_HOME} \ + && rm -f commandlinetools.zip \ + && yes | sdkmanager --licenses \ + && sdkmanager "platform-tools" "build-tools:33.0.2" COPY entrypoint.sh /usr/local/bin/ RUN chmod +x /usr/local/bin/entrypoint.sh -- GitLab From 30b29ca3ef33730578c1c02ff7e896cb11a12a94 Mon Sep 17 00:00:00 2001 From: Alan Nelson <alan.nelson@nebraska.edu> Date: Fri, 17 Mar 2023 11:11:10 -0500 Subject: [PATCH 3/6] Create containers for PHP 8.2 --- Makefile | 18 ++++++++++++------ php-lint/8.2/Dockerfile | 21 +++++++++++++++++++++ php-unit-test/8.2/Dockerfile | 25 +++++++++++++++++++++++++ 3 files changed, 58 insertions(+), 6 deletions(-) create mode 100644 php-lint/8.2/Dockerfile create mode 100644 php-unit-test/8.2/Dockerfile diff --git a/Makefile b/Makefile index 61eb9fb..69a643d 100644 --- a/Makefile +++ b/Makefile @@ -24,8 +24,8 @@ all: php-lint php-unit-test mobile static-code-analysis utility detect-secrets d # Image Groups #################### -php-lint: php-lint_5.6 php-lint_7.0 php-lint_7.1 php-lint_7.2 php-lint_7.3 php-lint_7.4 php-lint_8.0 php-lint_latest -php-unit-test: php-unit-test_5.6 php-unit-test_7.0 php-unit-test_7.1 php-unit-test_7.2 php-unit-test_7.3 php-unit-test_7.4 php-unit-test_8.0 php-unit-test_latest +php-lint: php-lint_5.6 php-lint_7.0 php-lint_7.1 php-lint_7.2 php-lint_7.3 php-lint_7.4 php-lint_8.0 php-lint_8.1 php-lint_8.2 php-lint_latest +php-unit-test: php-unit-test_5.6 php-unit-test_7.0 php-unit-test_7.1 php-unit-test_7.2 php-unit-test_7.3 php-unit-test_7.4 php-unit-test_8.0 php-unit-test_8.1 php-unit-test_8.2 php-unit-test_latest mobile: android-build-server static-code-analysis: static-code-analysis_latest static-code-analysys_php static-code-analysys_python static-code-analysys_android utility: alpine-ssh-client merge-request-check @@ -57,8 +57,11 @@ php-lint_8.0: php-lint/8.0/Dockerfile php-lint_8.1: php-lint/8.1/Dockerfile docker build $(BUILD_ARGS) -t ${REPO_ORG}/php-lint:8.1 -f php-lint/8.1/Dockerfile php-lint -php-lint_latest: php-lint_8.1 - docker tag ${REPO_ORG}/php-lint:8.1 ${REPO_ORG}/php-lint:latest +php-lint_8.2: php-lint/8.2/Dockerfile + docker build $(BUILD_ARGS) -t ${REPO_ORG}/php-lint:8.2 -f php-lint/8.2/Dockerfile php-lint + +php-lint_latest: php-lint_8.2 + docker tag ${REPO_ORG}/php-lint:8.2 ${REPO_ORG}/php-lint:latest # PHP Unit Test Images #################### @@ -86,8 +89,11 @@ php-unit-test_8.0: php-unit-test/8.0/Dockerfile php-unit-test_8.1: php-unit-test/8.1/Dockerfile docker build $(BUILD_ARGS) -t ${REPO_ORG}/php-unit-test:8.1 -f php-unit-test/8.1/Dockerfile php-unit-test -php-unit-test_latest: php-unit-test_8.1 - docker tag ${REPO_ORG}/php-unit-test:8.1 ${REPO_ORG}/php-unit-test:latest +php-unit-test_8.2: php-unit-test/8.2/Dockerfile + docker build $(BUILD_ARGS) -t ${REPO_ORG}/php-unit-test:8.2 -f php-unit-test/8.2/Dockerfile php-unit-test + +php-unit-test_latest: php-unit-test_8.2 + docker tag ${REPO_ORG}/php-unit-test:8.2 ${REPO_ORG}/php-unit-test:latest # Mobile Applications #################### diff --git a/php-lint/8.2/Dockerfile b/php-lint/8.2/Dockerfile new file mode 100644 index 0000000..0878a66 --- /dev/null +++ b/php-lint/8.2/Dockerfile @@ -0,0 +1,21 @@ +FROM php:8.2-alpine + +ARG BUILD_DATE +ARG VCS_REF +ARG VERSION +LABEL org.label-schema.build-date=$BUILD_DATE \ + org.label-schema.name="PHP 8.2 linter" \ + org.label-schema.description="" \ + org.label-schema.vcs-ref=$VCS_REF \ + org.label-schema.vendor="University of Nebraska - Lincoln" \ + org.label-schema.version=$VERSION \ + org.label-schema.schema-version="1.0" \ + maintainer="Alan Nelson <alan.nelson@nebraska.edu>" + +RUN apk add --no-cache bash + +COPY php-lint docker-entrypoint /usr/local/bin/ +RUN chmod 755 /usr/local/bin/docker-entrypoint /usr/local/bin/php-lint + +ENTRYPOINT ["docker-entrypoint"] +CMD ["--help"] diff --git a/php-unit-test/8.2/Dockerfile b/php-unit-test/8.2/Dockerfile new file mode 100644 index 0000000..fa6012d --- /dev/null +++ b/php-unit-test/8.2/Dockerfile @@ -0,0 +1,25 @@ +FROM php:8.2-alpine + +ARG BUILD_DATE +ARG VCS_REF +ARG VERSION +LABEL org.label-schema.build-date=$BUILD_DATE \ + org.label-schema.name="PHP 8.2 Unit Tester" \ + org.label-schema.description="" \ + org.label-schema.vcs-ref=$VCS_REF \ + org.label-schema.vendor="University of Nebraska - Lincoln" \ + org.label-schema.version=$VERSION \ + org.label-schema.schema-version="1.0" \ + maintainer="Alan Nelson <alan.nelson@nebraska.edu>" + +RUN export BUILD_DEPS="bzip2-dev icu-dev libpng-dev libzip-dev openldap-dev" \ + && apk add --no-cache bash nodejs npm $PHPIZE_DEPS $BUILD_DEPS \ + && pecl channel-update pecl.php.net \ + && pecl install xdebug redis \ + && docker-php-ext-install bz2 gd intl ldap mysqli pdo_mysql zip \ + && docker-php-ext-enable xdebug redis \ + && apk del --no-cache $PHPIZE_DEPS +RUN curl -o /usr/local/bin/composer https://getcomposer.org/composer.phar \ + && chmod 755 /usr/local/bin/composer + +CMD ["bash"] -- GitLab From 6c21fbf638b123b52d71b0c366b960d02cfa286e Mon Sep 17 00:00:00 2001 From: Alan Nelson <alan.nelson@nebraska.edu> Date: Fri, 17 Mar 2023 11:46:40 -0500 Subject: [PATCH 4/6] Update Android build container --- android-build-server/Dockerfile | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/android-build-server/Dockerfile b/android-build-server/Dockerfile index ad72627..edd1592 100644 --- a/android-build-server/Dockerfile +++ b/android-build-server/Dockerfile @@ -14,16 +14,17 @@ LABEL org.label-schema.build-date=$BUILD_DATE \ ENV ANDROID_HOME /opt/android-sdk-linux -ENV PATH ${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/tools/bin:${ANDROID_HOME}/platform-tools:${ANDROID_HOME}/cmdline-tools/bin +ENV PATH ${PATH}:${ANDROID_HOME}/tools:${ANDROID_HOME}/tools/bin:${ANDROID_HOME}/platform-tools:${ANDROID_HOME}/cmdline-tools/latest/bin WORKDIR /opt RUN apk add --no-cache curl bash unzip libstdc++ su-exec -RUN mkdir -p /opt/android-sdk-linux \ +RUN mkdir -p /opt/android-sdk-linux/cmdline-tools \ && curl -q -o commandlinetools.zip -L https://dl.google.com/android/repository/commandlinetools-linux-9477386_latest.zip \ - && unzip -q commandlinetools.zip -d ${ANDROID_HOME} \ - && rm -f commandlinetools.zip \ - && yes | sdkmanager --licenses \ - && sdkmanager "platform-tools" "build-tools:33.0.2" + && unzip -q commandlinetools.zip -d ${ANDROID_HOME}/cmdline-tools \ + && mv ${ANDROID_HOME}/cmdline-tools/cmdline-tools ${ANDROID_HOME}/cmdline-tools/latest \ + && rm -f commandlinetools.zip +RUN sdkmanager "platform-tools" +RUN yes | sdkmanager --licenses COPY entrypoint.sh /usr/local/bin/ RUN chmod +x /usr/local/bin/entrypoint.sh -- GitLab From 1f064fc0b56f8c94d324b4b66076aff996af991c Mon Sep 17 00:00:00 2001 From: Alan Nelson <alan.nelson@nebraska.edu> Date: Fri, 17 Mar 2023 11:56:25 -0500 Subject: [PATCH 5/6] Lock xdebug version on older PHP containers --- php-unit-test/7.2/Dockerfile | 2 +- php-unit-test/7.3/Dockerfile | 2 +- php-unit-test/7.4/Dockerfile | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/php-unit-test/7.2/Dockerfile b/php-unit-test/7.2/Dockerfile index 3f5705d..4615de0 100644 --- a/php-unit-test/7.2/Dockerfile +++ b/php-unit-test/7.2/Dockerfile @@ -14,7 +14,7 @@ LABEL org.label-schema.build-date=$BUILD_DATE \ RUN apk add --no-cache bash nodejs nodejs-npm $PHPIZE_DEPS \ && pecl channel-update pecl.php.net \ - && pecl install xdebug redis \ + && pecl install xdebug-3.1.6 redis \ && docker-php-ext-enable xdebug redis \ && apk del --no-cache $PHPIZE_DEPS RUN curl -o /usr/local/bin/composer https://getcomposer.org/composer.phar \ diff --git a/php-unit-test/7.3/Dockerfile b/php-unit-test/7.3/Dockerfile index 23d6386..1e7a5e5 100644 --- a/php-unit-test/7.3/Dockerfile +++ b/php-unit-test/7.3/Dockerfile @@ -15,7 +15,7 @@ LABEL org.label-schema.build-date=$BUILD_DATE \ RUN export BUILD_DEPS="bzip2-dev icu-dev libpng-dev libzip-dev openldap-dev" \ && apk add --no-cache bash nodejs nodejs-npm $PHPIZE_DEPS $BUILD_DEPS \ && pecl channel-update pecl.php.net \ - && pecl install xdebug redis \ + && pecl install xdebug-3.1.6 redis \ && docker-php-ext-install bz2 gd intl ldap mysqli pdo_mysql zip \ && docker-php-ext-enable xdebug redis \ && apk del --no-cache $PHPIZE_DEPS diff --git a/php-unit-test/7.4/Dockerfile b/php-unit-test/7.4/Dockerfile index e547b9e..80c63c5 100644 --- a/php-unit-test/7.4/Dockerfile +++ b/php-unit-test/7.4/Dockerfile @@ -15,7 +15,7 @@ LABEL org.label-schema.build-date=$BUILD_DATE \ RUN export BUILD_DEPS="bzip2-dev icu-dev libpng-dev libzip-dev openldap-dev" \ && apk add --no-cache bash nodejs nodejs-npm $PHPIZE_DEPS $BUILD_DEPS \ && pecl channel-update pecl.php.net \ - && pecl install xdebug redis \ + && pecl install xdebug-3.1.6 redis \ && docker-php-ext-install bz2 gd intl ldap mysqli pdo_mysql zip \ && docker-php-ext-enable xdebug redis \ && apk del --no-cache $PHPIZE_DEPS -- GitLab From 42a82c157cb6420c93a0bafabbf1ad1562edc890 Mon Sep 17 00:00:00 2001 From: Alan Nelson <alan.nelson@nebraska.edu> Date: Fri, 17 Mar 2023 12:09:02 -0500 Subject: [PATCH 6/6] Update PHP build deps --- php-unit-test/8.0/Dockerfile | 2 +- php-unit-test/8.1/Dockerfile | 2 +- php-unit-test/8.2/Dockerfile | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/php-unit-test/8.0/Dockerfile b/php-unit-test/8.0/Dockerfile index f5721eb..52c9e49 100644 --- a/php-unit-test/8.0/Dockerfile +++ b/php-unit-test/8.0/Dockerfile @@ -13,7 +13,7 @@ LABEL org.label-schema.build-date=$BUILD_DATE \ maintainer="Alan Nelson <alan.nelson@nebraska.edu>" RUN export BUILD_DEPS="bzip2-dev icu-dev libpng-dev libzip-dev openldap-dev" \ - && apk add --no-cache bash nodejs nodejs-npm $PHPIZE_DEPS $BUILD_DEPS \ + && apk add --no-cache bash nodejs nodejs-npm linux-headers $PHPIZE_DEPS $BUILD_DEPS \ && pecl channel-update pecl.php.net \ && pecl install xdebug redis \ && docker-php-ext-install bz2 gd intl ldap mysqli pdo_mysql zip \ diff --git a/php-unit-test/8.1/Dockerfile b/php-unit-test/8.1/Dockerfile index 77db171..0eceb72 100644 --- a/php-unit-test/8.1/Dockerfile +++ b/php-unit-test/8.1/Dockerfile @@ -13,7 +13,7 @@ LABEL org.label-schema.build-date=$BUILD_DATE \ maintainer="Alan Nelson <alan.nelson@nebraska.edu>" RUN export BUILD_DEPS="bzip2-dev icu-dev libpng-dev libzip-dev openldap-dev" \ - && apk add --no-cache bash nodejs npm $PHPIZE_DEPS $BUILD_DEPS \ + && apk add --no-cache bash nodejs npm linux-headers $PHPIZE_DEPS $BUILD_DEPS \ && pecl channel-update pecl.php.net \ && pecl install xdebug redis \ && docker-php-ext-install bz2 gd intl ldap mysqli pdo_mysql zip \ diff --git a/php-unit-test/8.2/Dockerfile b/php-unit-test/8.2/Dockerfile index fa6012d..a4dd31f 100644 --- a/php-unit-test/8.2/Dockerfile +++ b/php-unit-test/8.2/Dockerfile @@ -13,7 +13,7 @@ LABEL org.label-schema.build-date=$BUILD_DATE \ maintainer="Alan Nelson <alan.nelson@nebraska.edu>" RUN export BUILD_DEPS="bzip2-dev icu-dev libpng-dev libzip-dev openldap-dev" \ - && apk add --no-cache bash nodejs npm $PHPIZE_DEPS $BUILD_DEPS \ + && apk add --no-cache bash nodejs npm linux-headers $PHPIZE_DEPS $BUILD_DEPS \ && pecl channel-update pecl.php.net \ && pecl install xdebug redis \ && docker-php-ext-install bz2 gd intl ldap mysqli pdo_mysql zip \ -- GitLab