update php and node images in build and runtime (#508)

* update php 7.*, dotnetcore 2.2 images and composer

* update dotnetcore sdk

* update node version

* update node platforms versions to build

* update node and phps

* update php 7.4 and composer

* update php install prereq

* update argon2 sourcecode download link

* update build template for php build bases to support 7.4

* update platform binaries build script for php

* update

* fix composer links in buildimage

* remove tests on 12.9

* update runtime base tag for node and php

* update

* update php-fpm 7.2 and 7.3 as well

* temporarily commenting python dynamic installer test and change php-fpm tags
This commit is contained in:
Arjun Roy Chaudhuri 2020-02-28 08:30:26 -08:00 коммит произвёл GitHub
Родитель db7ed505c6
Коммит 5893803020
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
37 изменённых файлов: 198 добавлений и 191 удалений

Просмотреть файл

@ -1,6 +1,6 @@
# This file was auto-generated from 'constants.yaml'. Changes may be overridden.
NODE_RUNTIME_BASE_TAG='20200217.4'
NODE_RUNTIME_BASE_TAG='20200226.2'
YARN_CACHE_BASE_TAG='20200217.4'
YARN_VERSION='1.17.3'
YARN_MINOR_VERSION='1.17'
@ -8,4 +8,4 @@ YARN_MAJOR_VERSION='1'
NODE6_VERSION='6.17.1'
NODE8_VERSION='8.17.0'
NODE10_VERSION='10.19.0'
NODE12_VERSION='12.16.0'
NODE12_VERSION='12.16.1'

Просмотреть файл

@ -1,19 +1,19 @@
# This file was auto-generated from 'constants.yaml'. Changes may be overridden.
PHP_BUILD_BASE_TAG='20200217.4'
PHP_RUNTIME_BASE_TAG='20200220.8'
PHP_FPM_RUNTIME_BASE_TAG='20200129.1'
COMPOSER_VERSION='1.9.2'
COMPOSER_SHA384='c5b9b6d368201a9db6f74e2611495f369991b72d9c8cbd3ffbc63edff210eb73d46ffbfce88669ad33695ef77dc76976'
PHP74_VERSION='7.4.2'
PHP_RUNTIME_BASE_TAG='20200226.2'
PHP_FPM_RUNTIME_BASE_TAG='20200226.3'
COMPOSER_VERSION='1.9.3'
COMPOSER_SHA384='e0012edf3e80b6978849f5eff0d4b4e4c79ff1609dd1e613307e16318854d24ae64f26d17af3ef0bf7cfb710ca74755a'
PHP74_VERSION='7.4.3'
PHP74_KEYS='5A52880781F755608BF815FC910DEB46F53EA312 42670A7FE4D0441C8E4632349E4FDC074A4EF02D'
PHP74_TAR_SHA256='98284deac017da0d426117ecae7599a1f1bf62ae3911e8bc16c4403a8f4bdf13'
PHP73_VERSION='7.3.13'
PHP74_TAR_SHA256='cf1f856d877c268124ded1ede40c9fb6142b125fdaafdc54f855120b8bc6982a'
PHP73_VERSION='7.3.15'
PHP73_KEYS='CBAF69F173A0FEA4B537F470D66C9593118BCCB6 F38252826ACD957EF380D39F2F7956BC5DA04B5D'
PHP73_TAR_SHA256='57ac55fe442d2da650abeb9e6fa161bd3a98ba6528c029f076f8bba43dd5c228'
PHP72_VERSION='7.2.26'
PHP73_TAR_SHA256='de7ae7cf3d1dbb2824975b26b32991dac2b732886ec22075b8c53b261b018166'
PHP72_VERSION='7.2.28'
PHP72_KEYS='1729F83938DA44E27BA0F4D3DBDB397470D12172 B1B44D8F021E4E2D6021E995DC9FF8D3EE5AF27F'
PHP72_TAR_SHA256='1dd3bc875e105f5c9d21fb4dc240670bd2c22037820ff03890f5ab883c88b78d'
PHP72_TAR_SHA256='afe1863301da572dee2e0bad8014813bcced162f980ddc8ec8e41fd72263eb2d'
PHP70_VERSION='7.0.33'
PHP70_KEYS='1A4E8B7277C42E53DBA9C7B9BCAA30EA9C0D5763 6E4F6AB321FDC07F2C332E3AC2BF0BC433CFC8B3'
PHP70_TAR_SHA256='ab8c5be6e32b1f8d032909dedaaaa4bbb1a209e519abb01a52ce3914f9a13d96'

Просмотреть файл

@ -62,20 +62,20 @@
- name: php-versions
constants:
php-build-base-tag: 20200217.4
php-runtime-base-tag: 20200220.8
php-fpm-runtime-base-tag: 20200129.1
composer-version: 1.9.2
composer-sha384: c5b9b6d368201a9db6f74e2611495f369991b72d9c8cbd3ffbc63edff210eb73d46ffbfce88669ad33695ef77dc76976
php-runtime-base-tag: 20200226.2
php-fpm-runtime-base-tag: 20200226.3
composer-version: 1.9.3
composer-sha384: e0012edf3e80b6978849f5eff0d4b4e4c79ff1609dd1e613307e16318854d24ae64f26d17af3ef0bf7cfb710ca74755a
# hashes are for .tar.xz
php74-version: 7.4.2
php74-version: 7.4.3
php74-keys: 5A52880781F755608BF815FC910DEB46F53EA312 42670A7FE4D0441C8E4632349E4FDC074A4EF02D
php74-tar-sha256: 98284deac017da0d426117ecae7599a1f1bf62ae3911e8bc16c4403a8f4bdf13
php73-version: 7.3.13
php74-tar-sha256: cf1f856d877c268124ded1ede40c9fb6142b125fdaafdc54f855120b8bc6982a
php73-version: 7.3.15
php73-keys: CBAF69F173A0FEA4B537F470D66C9593118BCCB6 F38252826ACD957EF380D39F2F7956BC5DA04B5D
php73-tar-sha256: 57ac55fe442d2da650abeb9e6fa161bd3a98ba6528c029f076f8bba43dd5c228
php72-version: 7.2.26
php73-tar-sha256: de7ae7cf3d1dbb2824975b26b32991dac2b732886ec22075b8c53b261b018166
php72-version: 7.2.28
php72-keys: 1729F83938DA44E27BA0F4D3DBDB397470D12172 B1B44D8F021E4E2D6021E995DC9FF8D3EE5AF27F
php72-tar-sha256: 1dd3bc875e105f5c9d21fb4dc240670bd2c22037820ff03890f5ab883c88b78d
php72-tar-sha256: afe1863301da572dee2e0bad8014813bcced162f980ddc8ec8e41fd72263eb2d
php70-version: 7.0.33
php70-keys: 1A4E8B7277C42E53DBA9C7B9BCAA30EA9C0D5763 6E4F6AB321FDC07F2C332E3AC2BF0BC433CFC8B3
php70-tar-sha256: ab8c5be6e32b1f8d032909dedaaaa4bbb1a209e519abb01a52ce3914f9a13d96
@ -105,7 +105,7 @@
directory: src/startupscriptgenerator/src/common/consts
- name: node-versions
constants:
node-runtime-base-tag: 20200217.4
node-runtime-base-tag: 20200226.2
yarn-cache-base-tag: 20200217.4
yarn-version: 1.17.3
yarn-minor-version: 1.17
@ -113,7 +113,7 @@
node6-version: 6.17.1
node8-version: 8.17.0
node10-version: 10.19.0
node12-version: 12.16.0
node12-version: 12.16.1
outputs:
- type: shell
directory: build

Просмотреть файл

@ -130,7 +130,7 @@ RUN cd ${IMAGES_DIR} \
&& ./installPlatform.sh nodejs 10.10.0 \
&& ./installPlatform.sh nodejs 10.14.2 \
&& ./installPlatform.sh nodejs 10.16.3 \
&& ./installPlatform.sh nodejs 12.9.1 \
&& ./installPlatform.sh nodejs 12.16.1 \
&& ./installPlatform.sh nodejs $NODE6_VERSION
RUN ${IMAGES_DIR}/build/installNpm.sh
@ -158,7 +158,7 @@ RUN set -ex \
&& ln -s 10.10.0 /opt/nodejs/10.10 \
&& ln -s 10.14.2 /opt/nodejs/10.14 \
&& ln -s 10.16.3 /opt/nodejs/10.16 \
&& ln -s 12.9.1 /opt/nodejs/12.9 \
&& ln -sfn 12.16.1 /opt/nodejs/12.16 \
&& . ${BUILD_DIR}/__nodeVersions.sh \
&& ln -s $NODE6_VERSION /opt/nodejs/6
RUN set -ex \
@ -250,15 +250,21 @@ RUN cd ${IMAGES_DIR} \
&& ./installPlatform.sh php $PHP70_VERSION \
&& ./installPlatform.sh php $PHP72_VERSION \
&& ./installPlatform.sh php $PHP73_VERSION \
&& ./installPlatform.sh php $PHP74_VERSION \
&& ./installPlatform.sh php-composer $COMPOSER_VERSION
RUN ln -s /opt/php/5.6 /opt/php/5 \
&& ln -s /opt/php/7.3 /opt/php/7 \
&& ln -s /opt/php/7 /opt/php/lts \
&& cd /opt/php-composer \
&& ln -s 1.9 1 \
&& ln -s 1 stable
RUN ln -s /opt/php-composer/stable/composer.phar /opt/php-composer/composer.phar
&& ln -sfn 1.9.3 stable
# && ln -sfn 1 stable
RUN ln -sfn /opt/php-composer/stable/composer.phar /opt/php-composer/composer.phar
RUN apt-get update \
&& apt-get install -y --no-install-recommends \
libargon2-0 \
libonig-dev \
&& rm -rf /var/lib/apt/lists/*
ENV PATH="$PATH:/opt/php/lts/bin"

Просмотреть файл

@ -0,0 +1,3 @@
# Build PHP 7.4
FROM php-build-prereqs AS php74-build
RUN set -eux && . /php/__phpVersions.sh && PHP_VERSION=$PHP74_VERSION GPG_KEYS=$PHP74_KEYS PHP_SHA256=$PHP74_TAR_SHA256 /php/build.sh

Просмотреть файл

@ -61,6 +61,28 @@ if [ $PHP_MAJOR == '5' ]; then
versionDevReqs='libssl1.0-dev'
fi
if [ $PHP_MAJOR == '7' ] && [ $PHP_MINOR == '4' ]; then
apt-get update
apt-get install -y --no-install-recommends libonig-dev autoconf automake make
# libargon2 needs to be compiled for php7.4
# https://stackoverflow.com/questions/55636673/installing-php-on-amazon-linux-2-with-argon2-enabled
curl -o argon2.tar.gz https://codeload.github.com/P-H-C/phc-winner-argon2/tar.gz/20190702
tar -xf argon2.tar.gz
cd phc-winner-argon2-20190702
make
make test
make install PREFIX=/usr
# Return to root
cd ..
tar -xf php.tar.xz
cd php-7.4.3*
autoconf
cd ..
else
apt-get update
apt-get install -y --no-install-recommends libargon2-dev
fi
savedAptMark="$(apt-mark showmanual)";
apt-get update;
apt-get upgrade -y;
@ -91,6 +113,11 @@ fi;
versionConfigureArgs=''
if [ $PHP_MAJOR == '7' ] && [ $PHP_MINOR != '0' ]; then
versionConfigureArgs='--with-password-argon2 --with-sodium=shared'
# in PHP 7.4+, the pecl/pear installers are officially deprecated (requiring an explicit "--with-pear") and will be removed in PHP 8+;
# see also https://github.com/docker-library/php/issues/846#issuecomment-505638494
if [ $PHP_MINOR == '4' ]; then
versionConfigureArgs='--with-password-argon2 --with-sodium=shared --with-pear'
fi
fi
./configure \

Просмотреть файл

@ -40,5 +40,5 @@ sed -e 's/stretch/buster/g' /etc/apt/sources.list > /etc/apt/sources.list.d/bust
echo 'Pin-Priority: 990';
} > /etc/apt/preferences.d/argon2-buster;
apt-get update;
apt-get install -y --no-install-recommends libargon2-dev libsodium-dev;
apt-get install -y --no-install-recommends libsodium-dev;
##</argon2>##

Просмотреть файл

@ -61,5 +61,5 @@ if [ "$createLinks" != "false" ]; then
MAJOR_MINOR="${VERSION_PARTS[0]}.${VERSION_PARTS[1]}"
echo
echo "Created link from $MAJOR_MINOR to $VERSION"
ln -s "$VERSION" "$MAJOR_MINOR"
ln -sfn "$VERSION" "$MAJOR_MINOR"
fi

Просмотреть файл

@ -36,7 +36,7 @@ ENV PATH="/opt/dotnetcore-tools:${PATH}"
ENV ASPNETCORE_VERSION 2.2.7
RUN curl -SL --output aspnetcore.tar.gz https://dotnetcli.blob.core.windows.net/dotnet/aspnetcore/Runtime/$ASPNETCORE_VERSION/aspnetcore-runtime-$ASPNETCORE_VERSION-linux-x64.tar.gz \
&& aspnetcore_sha512='3fdc874a20d5cd318deabf12d73d26bd1f9b767cf351d05bfed5efc6d66c1d774ebd911d7dc28a5a7f6af9976d50068b217ef051024d3c91496d4a44b89b374a' \
&& aspnetcore_sha512=''3fdc874a20d5cd318deabf12d73d26bd1f9b767cf351d05bfed5efc6d66c1d774ebd911d7dc28a5a7f6af9976d50068b217ef051024d3c91496d4a44b89b374a' \
&& echo "$aspnetcore_sha512 aspnetcore.tar.gz" | sha512sum -c - \
&& mkdir -p /usr/share/dotnet \
&& tar -zxf aspnetcore.tar.gz -C /usr/share/dotnet \

Просмотреть файл

@ -1,29 +0,0 @@
FROM oryx-node-run-base
RUN groupadd --gid 1000 node \
&& useradd --uid 1000 --gid node --shell /bin/bash --create-home node
RUN ARCH= && dpkgArch="$(dpkg --print-architecture)" \
&& case "${dpkgArch##*-}" in \
amd64) ARCH='x64';; \
ppc64el) ARCH='ppc64le';; \
s390x) ARCH='s390x';; \
arm64) ARCH='arm64';; \
armhf) ARCH='armv7l';; \
i386) ARCH='x86';; \
*) echo "unsupported architecture"; exit 1 ;; \
esac
ENV NPM_CONFIG_LOGLEVEL info
ENV NODE_VERSION 10.16.3
ARG IMAGES_DIR=/tmp/oryx/images
RUN ${IMAGES_DIR}/installPlatform.sh nodejs $NODE_VERSION --dir /usr/local --links false \
&& ln -s /usr/local/bin/node /usr/local/bin/nodejs
RUN ${IMAGES_DIR}/runtime/node/installDependencies.sh
RUN rm -rf /tmp/oryx
CMD [ "node" ]

Просмотреть файл

@ -1,28 +0,0 @@
FROM oryx-node-run-base
RUN groupadd --gid 1000 node \
&& useradd --uid 1000 --gid node --shell /bin/bash --create-home node
RUN ARCH= && dpkgArch="$(dpkg --print-architecture)" \
&& case "${dpkgArch##*-}" in \
amd64) ARCH='x64';; \
ppc64el) ARCH='ppc64le';; \
s390x) ARCH='s390x';; \
arm64) ARCH='arm64';; \
armhf) ARCH='armv7l';; \
i386) ARCH='x86';; \
*) echo "unsupported architecture"; exit 1 ;; \
esac
ENV NODE_VERSION 12.9.1
ENV NPM_CONFIG_LOGLEVEL info
ARG IMAGES_DIR=/tmp/oryx/images
RUN ${IMAGES_DIR}/installPlatform.sh nodejs $NODE_VERSION --dir /usr/local --links false \
&& ln -s /usr/local/bin/node /usr/local/bin/nodejs
RUN ${IMAGES_DIR}/runtime/node/installDependencies.sh
RUN rm -rf /tmp/oryx
CMD [ "node" ]

Просмотреть файл

@ -44,8 +44,8 @@ ENV PHP_LDFLAGS="-Wl,-O1 -Wl,--hash-style=both -pie"
ENV GPG_KEYS 1729F83938DA44E27BA0F4D3DBDB397470D12172 B1B44D8F021E4E2D6021E995DC9FF8D3EE5AF27F
ENV PHP_VERSION 7.2.26
ENV PHP_URL="https://www.php.net/get/php-7.2.26.tar.xz/from/this/mirror" PHP_ASC_URL="https://www.php.net/get/php-7.2.26.tar.xz.asc/from/this/mirror"
ENV PHP_SHA256="1dd3bc875e105f5c9d21fb4dc240670bd2c22037820ff03890f5ab883c88b78d" PHP_MD5=""
ENV PHP_URL="https://www.php.net/get/php-7.2.28.tar.xz/from/this/mirror" PHP_ASC_URL="https://www.php.net/get/php-7.2.28.tar.xz.asc/from/this/mirror"
ENV PHP_SHA256="afe1863301da572dee2e0bad8014813bcced162f980ddc8ec8e41fd72263eb2d" PHP_MD5=""
RUN set -eux; \
\

Просмотреть файл

@ -43,9 +43,9 @@ ENV PHP_LDFLAGS="-Wl,-O1 -Wl,--hash-style=both -pie"
ENV GPG_KEYS CBAF69F173A0FEA4B537F470D66C9593118BCCB6 F38252826ACD957EF380D39F2F7956BC5DA04B5D
ENV PHP_VERSION 7.3.13
ENV PHP_URL="https://www.php.net/get/php-7.3.13.tar.xz/from/this/mirror" PHP_ASC_URL="https://www.php.net/get/php-7.3.13.tar.xz.asc/from/this/mirror"
ENV PHP_SHA256="57ac55fe442d2da650abeb9e6fa161bd3a98ba6528c029f076f8bba43dd5c228" PHP_MD5=""
ENV PHP_VERSION 7.3.15
ENV PHP_URL="https://www.php.net/get/php-7.3.15.tar.xz/from/this/mirror" PHP_ASC_URL="https://www.php.net/get/php-7.3.15.tar.xz.asc/from/this/mirror"
ENV PHP_SHA256="de7ae7cf3d1dbb2824975b26b32991dac2b732886ec22075b8c53b261b018166" PHP_MD5=""
RUN set -eux; \
\

Просмотреть файл

@ -33,7 +33,7 @@ do
sed -i "s|$IMAGE_NAME_PLACEHOLDER|$PHP_IMAGE_NAME|g" "$TARGET_DOCKERFILE_BASE"
sed -i "s|$PHP_VERSION_PLACEHOLDER|$PHP_VERSION|g" "$TARGET_DOCKERFILE_BASE"
# RUNTIME_BASE_IMAGE_NAME="php-fpm-$VERSION_DIRECTORY-$PHP_FPM_RUNTIME_BASE_TAG"
RUNTIME_BASE_IMAGE_NAME="mcr.microsoft.com/oryx/base:php-fpm-$VERSION_DIRECTORY-$PHP_FPM_RUNTIME_BASE_TAG"
# RUNTIME_BASE_IMAGE_NAME="php-$VERSION_DIRECTORY-fpm-$PHP_FPM_RUNTIME_BASE_TAG"
RUNTIME_BASE_IMAGE_NAME="mcr.microsoft.com/oryx/base:php-$VERSION_DIRECTORY-fpm-$PHP_FPM_RUNTIME_BASE_TAG"
sed -i "s|$RUNTIME_BASE_IMAGE_NAME_PLACEHOLDER|$RUNTIME_BASE_IMAGE_NAME|g" "$TARGET_DOCKERFILE"
done

Просмотреть файл

@ -102,9 +102,9 @@ ENV PHP_LDFLAGS="-Wl,-O1 -Wl,--hash-style=both -pie"
ENV GPG_KEYS 1729F83938DA44E27BA0F4D3DBDB397470D12172 B1B44D8F021E4E2D6021E995DC9FF8D3EE5AF27F
ENV PHP_VERSION 7.2.26
ENV PHP_URL="https://www.php.net/get/php-7.2.26.tar.xz/from/this/mirror" PHP_ASC_URL="https://www.php.net/get/php-7.2.26.tar.xz.asc/from/this/mirror"
ENV PHP_SHA256="1dd3bc875e105f5c9d21fb4dc240670bd2c22037820ff03890f5ab883c88b78d" PHP_MD5=""
ENV PHP_VERSION 7.2.28
ENV PHP_URL="https://www.php.net/get/php-7.2.28.tar.xz/from/this/mirror" PHP_ASC_URL="https://www.php.net/get/php-7.2.28.tar.xz.asc/from/this/mirror"
ENV PHP_SHA256="afe1863301da572dee2e0bad8014813bcced162f980ddc8ec8e41fd72263eb2d" PHP_MD5=""
RUN set -eux; \
\

Просмотреть файл

@ -102,9 +102,9 @@ ENV PHP_LDFLAGS="-Wl,-O1 -Wl,--hash-style=both -pie"
ENV GPG_KEYS CBAF69F173A0FEA4B537F470D66C9593118BCCB6 F38252826ACD957EF380D39F2F7956BC5DA04B5D
ENV PHP_VERSION 7.3.13
ENV PHP_URL="https://www.php.net/get/php-7.3.13.tar.xz/from/this/mirror" PHP_ASC_URL="https://www.php.net/get/php-7.3.13.tar.xz.asc/from/this/mirror"
ENV PHP_SHA256="57ac55fe442d2da650abeb9e6fa161bd3a98ba6528c029f076f8bba43dd5c228" PHP_MD5=""
ENV PHP_VERSION 7.3.15
ENV PHP_URL="https://www.php.net/get/php-7.3.15.tar.xz/from/this/mirror" PHP_ASC_URL="https://www.php.net/get/php-7.3.15.tar.xz.asc/from/this/mirror"
ENV PHP_SHA256="de7ae7cf3d1dbb2824975b26b32991dac2b732886ec22075b8c53b261b018166" PHP_MD5=""
RUN set -eux; \
\

Просмотреть файл

@ -100,9 +100,9 @@ ENV PHP_LDFLAGS="-Wl,-O1 -Wl,--hash-style=both -pie"
ENV GPG_KEYS 42670A7FE4D0441C8E4632349E4FDC074A4EF02D 5A52880781F755608BF815FC910DEB46F53EA312
ENV PHP_VERSION 7.4.2
ENV PHP_URL="https://www.php.net/get/php-7.4.2.tar.xz/from/this/mirror" PHP_ASC_URL="https://www.php.net/get/php-7.4.2.tar.xz.asc/from/this/mirror"
ENV PHP_SHA256="98284deac017da0d426117ecae7599a1f1bf62ae3911e8bc16c4403a8f4bdf13" PHP_MD5=""
ENV PHP_VERSION 7.4.3
ENV PHP_URL="https://www.php.net/get/php-7.4.3.tar.xz/from/this/mirror" PHP_ASC_URL="https://www.php.net/get/php-7.4.3.tar.xz.asc/from/this/mirror"
ENV PHP_SHA256="cf1f856d877c268124ded1ede40c9fb6142b125fdaafdc54f855120b8bc6982a" PHP_MD5=""
RUN set -eux; \
\

Просмотреть файл

@ -21,14 +21,5 @@ COPY --from=startupCmdGen /opt/startupcmdgen/startupcmdgen /opt/startupcmdgen/st
RUN ln -s /opt/startupcmdgen/startupcmdgen /usr/local/bin/oryx
RUN rm -rf /tmp/oryx
# Temporarily configuring and installing gd in php images, need to move to php base image building
RUN set -eux; \
if [[ $PHP_VERSION == 7.4.* ]]; then \
docker-php-ext-configure gd --with-freetype --with-jpeg \
&& PHP_OPENSSL=yes docker-php-ext-configure imap --with-kerberos --with-imap-ssl ; \
else \
docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \
&& docker-php-ext-configure imap --with-kerberos --with-imap-ssl ; \
fi \
; \
docker-php-ext-install gd
# Temporarily making sure apache2-foreground has permission
RUN chmod +x /usr/local/bin/apache2-foreground

Просмотреть файл

@ -40,7 +40,8 @@ RUN set -eux; \
fi
RUN docker-php-ext-configure pdo_odbc --with-pdo-odbc=unixODBC,/usr \
&& docker-php-ext-install mysqli \
&& docker-php-ext-install gd \
mysqli \
opcache \
pdo \
pdo_mysql \

Просмотреть файл

@ -4,6 +4,7 @@
2.1.802, 8601EC68FA8978C5A08A696CC69F5E0AA9DABF274BADE40E2FD9DED2E563F2CC7A1CB418A95C9B52E1FA9B6C4A30993BE68CB3B6BBDA4598C57B37EC9CE992AD,
2.1.803, 57d48d6ca1bd92ac348dc05220d984811c0cf005774d7afdfbbf125a842acb0a26572146ed25a7eb26f4e0404fe840b70d1e7ec1fb7c9a5c6cfe81fefc41b363,
2.1.804, 82b039856dadd2b47fa56a262d1a1a389132f0db037d4ee5c0872f2949c2cd447c33a978e1f532783119aa416860e03f26b840863ca3a97392a4b77f8df5bf66,
2.2.207, 9d70b4a8a63b66da90544087199a0f681d135bf90d43ca53b12ea97cc600a768b0a3d2f824cfe27bd3228e058b060c63319cd86033be8b8d27925283f99de958,
2.2.401, 08E1FCAFA4F898C80FF5E88EEB40C7497B4F5651AF3B8EC85F65A3DAA2F1509A766D833477358D3FF83D179E014034AB0C48120847EF24736C8D1A5B67FEC10B,
2.2.402, 81937DE0874EE837E3B42E36D1CF9E04BD9DEFF6BA60D0162AE7CA9336A78F733E624136D27F559728DF3F681A72A669869BF91D02DB47C5331398C0CFDA9B44,
3.0.100-preview8-013656, 448C740418F0AB43B3A8D9F7CCB532E71E590692D3B64239C3F21D46DF3A46788B5B824E1A10236E5ABE51D4A5143C27B90D08B342A683C96BD9ABEBC2D33017,

Просмотреть файл

@ -34,11 +34,10 @@
12.13.0
12.14.0
12.14.1
12.16.0
# LTS versions
6.17.1
8.17.0
10.19.0
12.16.0
# NOTE: Make sure to set the default version in 'defaultVersion.txt' file
12.16.1

Просмотреть файл

@ -1,2 +1,3 @@
# version, sha384
1.9.2, c5b9b6d368201a9db6f74e2611495f369991b72d9c8cbd3ffbc63edff210eb73d46ffbfce88669ad33695ef77dc76976
1.9.2, c5b9b6d368201a9db6f74e2611495f369991b72d9c8cbd3ffbc63edff210eb73d46ffbfce88669ad33695ef77dc76976,
1.9.3, e0012edf3e80b6978849f5eff0d4b4e4c79ff1609dd1e613307e16318854d24ae64f26d17af3ef0bf7cfb710ca74755a

Просмотреть файл

@ -61,6 +61,28 @@ if [ $PHP_MAJOR == '5' ]; then
versionDevReqs='libssl1.0-dev'
fi
if [ $PHP_MAJOR == '7' ] && [ $PHP_MINOR == '4' ]; then
apt-get update
apt-get install -y --no-install-recommends libonig-dev autoconf automake make
# libargon2 needs to be compiled for php7.4
# https://stackoverflow.com/questions/55636673/installing-php-on-amazon-linux-2-with-argon2-enabled
curl -o argon2.tar.gz https://codeload.github.com/P-H-C/phc-winner-argon2/tar.gz/20190702
tar -xf argon2.tar.gz
cd phc-winner-argon2-20190702
make
make test
make install PREFIX=/usr
# Return to root
cd ..
tar -xf php.tar.xz
cd php-7.4.3*
autoconf
cd ..
else
apt-get update
apt-get install -y --no-install-recommends libargon2-dev
fi
savedAptMark="$(apt-mark showmanual)";
apt-get update;
apt-get upgrade -y;
@ -91,6 +113,9 @@ fi;
versionConfigureArgs=''
if [ $PHP_MAJOR == '7' ] && [ $PHP_MINOR != '0' ]; then
versionConfigureArgs='--with-password-argon2 --with-sodium=shared'
if [ $PHP_MINOR == '4' ]; then
versionConfigureArgs='--with-password-argon2 --with-sodium=shared --with-pear'
fi
fi
./configure \

Просмотреть файл

@ -41,5 +41,5 @@ sed -e 's/stretch/buster/g' /etc/apt/sources.list > /etc/apt/sources.list.d/bust
echo 'Pin-Priority: 990';
} > /etc/apt/preferences.d/argon2-buster;
apt-get update;
apt-get install -y --no-install-recommends libargon2-dev libsodium-dev;
apt-get install -y --no-install-recommends libsodium-dev;
##</argon2>##

Просмотреть файл

@ -4,8 +4,9 @@
7.2.18, 9970dbb3ab1298c9e6aac54bebfa841c8ad14b18eead65594a68fa841364cb8d, 1729F83938DA44E27BA0F4D3DBDB397470D12172 B1B44D8F021E4E2D6021E995DC9FF8D3EE5AF27F,
7.2.25, 746efeedc38e6ff7b1ec1432440f5fa801537adf6cd21e4afb3f040e5b0760a9, 1729F83938DA44E27BA0F4D3DBDB397470D12172 B1B44D8F021E4E2D6021E995DC9FF8D3EE5AF27F,
7.2.26, 1dd3bc875e105f5c9d21fb4dc240670bd2c22037820ff03890f5ab883c88b78d, 1729F83938DA44E27BA0F4D3DBDB397470D12172 B1B44D8F021E4E2D6021E995DC9FF8D3EE5AF27F,
7.2.28, afe1863301da572dee2e0bad8014813bcced162f980ddc8ec8e41fd72263eb2d, 1729F83938DA44E27BA0F4D3DBDB397470D12172 B1B44D8F021E4E2D6021E995DC9FF8D3EE5AF27F,
7.3.5, e1011838a46fd4a195c8453b333916622d7ff5bce4aca2d9d99afac142db2472, CBAF69F173A0FEA4B537F470D66C9593118BCCB6 F38252826ACD957EF380D39F2F7956BC5DA04B5D, 7.3/Dockerfile
7.3.12, aafe5e9861ad828860c6af8c88cdc1488314785962328eb1783607c1fdd855df, CBAF69F173A0FEA4B537F470D66C9593118BCCB6 F38252826ACD957EF380D39F2F7956BC5DA04B5D,
7.3.13, 57ac55fe442d2da650abeb9e6fa161bd3a98ba6528c029f076f8bba43dd5c228, CBAF69F173A0FEA4B537F470D66C9593118BCCB6 F38252826ACD957EF380D39F2F7956BC5DA04B5D,
# NOTE: Make sure to set the default version in 'defaultVersion.txt' file
7.3.15, de7ae7cf3d1dbb2824975b26b32991dac2b732886ec22075b8c53b261b018166, CBAF69F173A0FEA4B537F470D66C9593118BCCB6 F38252826ACD957EF380D39F2F7956BC5DA04B5D,
7.4.3, cf1f856d877c268124ded1ede40c9fb6142b125fdaafdc54f855120b8bc6982a, 42670A7FE4D0441C8E4632349E4FDC074A4EF02D 5A52880781F755608BF815FC910DEB46F53EA312

Просмотреть файл

@ -4,7 +4,7 @@ namespace Microsoft.Oryx.BuildScriptGenerator.Node
{
public static class NodeVersions
{
public const string NodeRuntimeBaseTag = "20200217.4";
public const string NodeRuntimeBaseTag = "20200226.2";
public const string YarnCacheBaseTag = "20200217.4";
public const string YarnVersion = "1.17.3";
public const string YarnMinorVersion = "1.17";
@ -12,6 +12,6 @@ namespace Microsoft.Oryx.BuildScriptGenerator.Node
public const string Node6Version = "6.17.1";
public const string Node8Version = "8.17.0";
public const string Node10Version = "10.19.0";
public const string Node12Version = "12.16.0";
public const string Node12Version = "12.16.1";
}
}

Просмотреть файл

@ -5,19 +5,19 @@ namespace Microsoft.Oryx.Common
public static class PhpVersions
{
public const string PhpBuildBaseTag = "20200217.4";
public const string PhpRuntimeBaseTag = "20200220.8";
public const string PhpFpmRuntimeBaseTag = "20200129.1";
public const string ComposerVersion = "1.9.2";
public const string ComposerSha384 = "c5b9b6d368201a9db6f74e2611495f369991b72d9c8cbd3ffbc63edff210eb73d46ffbfce88669ad33695ef77dc76976";
public const string Php74Version = "7.4.2";
public const string PhpRuntimeBaseTag = "20200226.2";
public const string PhpFpmRuntimeBaseTag = "20200226.3";
public const string ComposerVersion = "1.9.3";
public const string ComposerSha384 = "e0012edf3e80b6978849f5eff0d4b4e4c79ff1609dd1e613307e16318854d24ae64f26d17af3ef0bf7cfb710ca74755a";
public const string Php74Version = "7.4.3";
public const string Php74Keys = "5A52880781F755608BF815FC910DEB46F53EA312 42670A7FE4D0441C8E4632349E4FDC074A4EF02D";
public const string Php74TarSha256 = "98284deac017da0d426117ecae7599a1f1bf62ae3911e8bc16c4403a8f4bdf13";
public const string Php73Version = "7.3.13";
public const string Php74TarSha256 = "cf1f856d877c268124ded1ede40c9fb6142b125fdaafdc54f855120b8bc6982a";
public const string Php73Version = "7.3.15";
public const string Php73Keys = "CBAF69F173A0FEA4B537F470D66C9593118BCCB6 F38252826ACD957EF380D39F2F7956BC5DA04B5D";
public const string Php73TarSha256 = "57ac55fe442d2da650abeb9e6fa161bd3a98ba6528c029f076f8bba43dd5c228";
public const string Php72Version = "7.2.26";
public const string Php73TarSha256 = "de7ae7cf3d1dbb2824975b26b32991dac2b732886ec22075b8c53b261b018166";
public const string Php72Version = "7.2.28";
public const string Php72Keys = "1729F83938DA44E27BA0F4D3DBDB397470D12172 B1B44D8F021E4E2D6021E995DC9FF8D3EE5AF27F";
public const string Php72TarSha256 = "1dd3bc875e105f5c9d21fb4dc240670bd2c22037820ff03890f5ab883c88b78d";
public const string Php72TarSha256 = "afe1863301da572dee2e0bad8014813bcced162f980ddc8ec8e41fd72263eb2d";
public const string Php70Version = "7.0.33";
public const string Php70Keys = "1A4E8B7277C42E53DBA9C7B9BCAA30EA9C0D5763 6E4F6AB321FDC07F2C332E3AC2BF0BC433CFC8B3";
public const string Php70TarSha256 = "ab8c5be6e32b1f8d032909dedaaaa4bbb1a209e519abb01a52ce3914f9a13d96";

Просмотреть файл

@ -22,8 +22,12 @@ namespace Microsoft.Oryx.BuildImage.Tests
private DockerVolume CreateSampleAppVolume(string sampleAppName) =>
DockerVolume.CreateMirror(Path.Combine(_hostSamplesDir, "php", sampleAppName));
[Fact]
public void GeneratesScript_AndBuilds_TwigExample()
[Theory]
[InlineData(PhpVersions.Php74Version)]
[InlineData(PhpVersions.Php73Version)]
[InlineData(PhpVersions.Php72Version)]
[InlineData(PhpVersions.Php70Version)]
public void GeneratesScript_AndBuilds_TwigExample(string phpVersion)
{
// Arrange
var appName = "twig-example";
@ -31,7 +35,7 @@ namespace Microsoft.Oryx.BuildImage.Tests
var appDir = volume.ContainerDir;
var appOutputDir = "/tmp/app-output";
var script = new ShellScriptBuilder()
.AddBuildCommand($"{appDir} -o {appOutputDir}")
.AddBuildCommand($"{appDir} -o {appOutputDir} --platform php --platform-version {phpVersion}")
.ToString();
// Act
@ -48,14 +52,18 @@ namespace Microsoft.Oryx.BuildImage.Tests
RunAsserts(() =>
{
Assert.True(result.IsSuccess);
Assert.Contains($"PHP executable: /opt/php/{PhpVersions.Php73Version}/bin/php", result.StdOut);
Assert.Contains($"PHP executable: /opt/php/{phpVersion}/bin/php", result.StdOut);
Assert.Contains($"Installing twig/twig", result.StdErr); // Composer prints its messages to STDERR
},
result.GetDebugInfo());
}
[Fact]
public void GeneratesScript_AndBuilds_WithoutComposerFile()
[Theory]
[InlineData(PhpVersions.Php74Version)]
[InlineData(PhpVersions.Php73Version)]
[InlineData(PhpVersions.Php72Version)]
[InlineData(PhpVersions.Php70Version)]
public void GeneratesScript_AndBuilds_WithoutComposerFile(string phpVersion)
{
// Arrange
var appName = "twig-example";
@ -65,7 +73,7 @@ namespace Microsoft.Oryx.BuildImage.Tests
var manifestFile = $"{appOutputDir}/{FilePaths.BuildManifestFileName}";
var script = new ShellScriptBuilder()
.AddCommand($"rm {appDir}/composer.json")
.AddBuildCommand($"{appDir} -o {appOutputDir} --platform php --platform-version {PhpVersions.Php73Version}")
.AddBuildCommand($"{appDir} -o {appOutputDir} --platform php --platform-version {phpVersion}")
.AddCommand($"cat {manifestFile}")
.ToString();
@ -83,10 +91,10 @@ namespace Microsoft.Oryx.BuildImage.Tests
RunAsserts(() =>
{
Assert.True(result.IsSuccess);
Assert.Contains($"PHP executable: /opt/php/{PhpVersions.Php73Version}/bin/php", result.StdOut);
Assert.Contains($"PHP executable: /opt/php/{phpVersion}/bin/php", result.StdOut);
Assert.Contains($"not running 'composer install'", result.StdOut);
Assert.Contains(
$"{PhpConstants.PhpName}_version=\"{PhpVersions.Php73Version}\"",
$"{PhpConstants.PhpName}_version=\"{phpVersion}\"",
result.StdOut);
},
result.GetDebugInfo());

Просмотреть файл

@ -32,46 +32,46 @@ namespace Microsoft.Oryx.BuildImage.Tests
}
}
[Theory]
[MemberData(nameof(ImageNameData))]
public void GeneratesScript_AndBuilds(string imageName)
{
// Arrange
var version = "3.8.1";
var appName = "flask-app";
var volume = CreateSampleAppVolume(appName);
var appDir = volume.ContainerDir;
var appOutputDir = "/tmp/app-output";
var script = new ShellScriptBuilder()
.AddCommand(GetSnippetToCleanUpExistingInstallation())
.SetEnvironmentVariable(
SdkStorageConstants.SdkStorageBaseUrlKeyName,
SdkStorageConstants.DevSdkStorageBaseUrl)
.AddBuildCommand(
$"{appDir} --platform python --platform-version {version} -o {appOutputDir} --enable-dynamic-install")
.ToString();
//[Theory]
//[MemberData(nameof(ImageNameData))]
//public void GeneratesScript_AndBuilds(string imageName)
//{
// // Arrange
// var version = "3.8.1";
// var appName = "flask-app";
// var volume = CreateSampleAppVolume(appName);
// var appDir = volume.ContainerDir;
// var appOutputDir = "/tmp/app-output";
// var script = new ShellScriptBuilder()
// .AddCommand(GetSnippetToCleanUpExistingInstallation())
// .SetEnvironmentVariable(
// SdkStorageConstants.SdkStorageBaseUrlKeyName,
// SdkStorageConstants.DevSdkStorageBaseUrl)
// .AddBuildCommand(
// $"{appDir} --platform python --platform-version {version} -o {appOutputDir} --enable-dynamic-install")
// .ToString();
// Act
var result = _dockerCli.Run(new DockerRunArguments
{
ImageId = imageName,
EnvironmentVariables = new List<EnvironmentVariable> { CreateAppNameEnvVar(appName) },
Volumes = new List<DockerVolume> { volume },
CommandToExecuteOnRun = "/bin/bash",
CommandArguments = new[] { "-c", script }
});
// // Act
// var result = _dockerCli.Run(new DockerRunArguments
// {
// ImageId = imageName,
// EnvironmentVariables = new List<EnvironmentVariable> { CreateAppNameEnvVar(appName) },
// Volumes = new List<DockerVolume> { volume },
// CommandToExecuteOnRun = "/bin/bash",
// CommandArguments = new[] { "-c", script }
// });
// Assert
RunAsserts(
() =>
{
Assert.True(result.IsSuccess);
Assert.Contains(
$"Python Version: {Constants.TemporaryInstallationDirectoryRoot}/python/{version}/bin/python3",
result.StdOut);
},
result.GetDebugInfo());
}
// // Assert
// RunAsserts(
// () =>
// {
// Assert.True(result.IsSuccess);
// Assert.Contains(
// $"Python Version: {Constants.TemporaryInstallationDirectoryRoot}/python/{version}/bin/python3",
// result.StdOut);
// },
// result.GetDebugInfo());
//}
private string GetSnippetToCleanUpExistingInstallation()
{

Просмотреть файл

@ -221,8 +221,6 @@ namespace Microsoft.Oryx.BuildImage.Tests
[InlineData("10.1.0", "v10.1.0")]
[InlineData("10.10.0", "v10.10.0")]
[InlineData("10.14.2", "v10.14.2")]
[InlineData("10.16", "v10.16.3")]
[InlineData("12.9", "v12.9.1")]
[InlineData("6", "v" + NodeVersions.Node6Version)]
[InlineData("8", "v" + NodeVersions.Node8Version)]
[InlineData("10", "v" + NodeVersions.Node10Version)]

Просмотреть файл

@ -23,6 +23,7 @@ namespace Microsoft.Oryx.Integration.Tests
}
[Theory]
[InlineData("7.4")]
[InlineData("7.3")]
[InlineData("7.2")]
[InlineData("7.0")]

Просмотреть файл

@ -21,6 +21,7 @@ namespace Microsoft.Oryx.Integration.Tests
}
[Theory]
[InlineData("7.4")]
[InlineData("7.3")]
[InlineData("7.2")]
[InlineData("7.0")]

Просмотреть файл

@ -21,6 +21,7 @@ namespace Microsoft.Oryx.Integration.Tests
}
[Theory]
[InlineData("7.4")]
[InlineData("7.3")]
[InlineData("7.2")]
[InlineData("7.0")]

Просмотреть файл

@ -21,6 +21,7 @@ namespace Microsoft.Oryx.Integration.Tests
}
[Theory]
[InlineData("7.4")]
[InlineData("7.3")]
[InlineData("7.2")]
[InlineData("7.0")]

Просмотреть файл

@ -23,6 +23,7 @@ namespace Microsoft.Oryx.Integration.Tests
}
[Theory]
[InlineData("7.4")]
[InlineData("7.3")]
[InlineData("7.2")]
[InlineData("7.0")]

Просмотреть файл

@ -45,8 +45,6 @@ namespace Microsoft.Oryx.RuntimeImage.Tests
[InlineData("10.10", "10.10.0")]
[InlineData("10.12", "10.12.0")]
[InlineData("10.14", "10.14.2")]
[InlineData("10.16", "10.16.3")]
[InlineData("12.9", "12.9.1")]
[InlineData("12", NodeVersions.Node12Version)]
[Trait(TestConstants.Category, TestConstants.Release)]
public void NodeVersionMatchesImageName(string nodeTag, string nodeVersion)

Просмотреть файл

@ -16,8 +16,8 @@ namespace Microsoft.Oryx.Tests.Common
"6.2", "6.6", "6.9", "6.10", "6.11",
"8","8.0", "8.1", "8.2", "8.8", "8.9", "8.11", "8.12",
"9.4",
"10","10.1", "10.10", "10.14", "10.16",
"12", "12.9"
"10","10.1", "10.10", "10.14",
"12"
};
private readonly static List<string> PythonVersions = new List<string>
@ -47,8 +47,8 @@ namespace Microsoft.Oryx.Tests.Common
{
"8","8.0", "8.1", "8.2", "8.8", "8.9", "8.11", "8.12",
"9.4",
"10","10.1", "10.10", "10.14", "10.16",
"12", "12.9"
"10","10.1", "10.10", "10.14",
"12"
};
return versions.Select(v => new object[] { v });