mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-07 08:34:42 +01:00
docker files for 7.4 builds
This commit is contained in:
parent
e1c1a3e4b7
commit
d422c5ad62
@ -17,7 +17,7 @@ RUN apt-get update \
|
||||
&& apt-get install -y software-properties-common \
|
||||
&& LC_ALL=C.UTF-8 add-apt-repository -y ppa:ondrej/php \
|
||||
&& apt-get update \
|
||||
&& bash -c "apt-get install -y php$PHP_VERSION-{cli,mysql,json,gd,xsl,bz2,opcache,apcu,tidy,zip,bcmath,mbstring,smbclient,ldap,curl,fpm,pgsql,gmp}" \
|
||||
&& bash -c "apt-get install -y php$PHP_VERSION-{cli,mysql,json,gd,xsl,bz2,opcache,apcu,tidy,zip,bcmath,mbstring,smbclient,ldap,curl,fpm,pgsql,gmp,memcached}" \
|
||||
# fpm and php.ini settings
|
||||
&& sed -e 's/^;\?listen \?=.*/listen = 9000/g' \
|
||||
-e '/allowed_clients/d' \
|
||||
|
@ -1,5 +1,16 @@
|
||||
#!/bin/bash -x
|
||||
|
||||
cd $(dirname $0)
|
||||
|
||||
DEFAULT_PHP_VERSION=7.4
|
||||
PHP_VERSION=$DEFAULT_PHP_VERSION
|
||||
|
||||
if [[ $1 =~ ^[78]\.[0-9]$ ]]
|
||||
then
|
||||
PHP_VERSION=$1
|
||||
shift
|
||||
fi
|
||||
|
||||
DEFAULT=$(git branch|grep ^*|cut -c3-)
|
||||
TAG=${1:-$DEFAULT}
|
||||
VERSION=$TAG
|
||||
@ -15,18 +26,21 @@ BRANCH=$(echo $VERSION|sed 's/\.[0-9]\{8\}$//')
|
||||
}
|
||||
}
|
||||
|
||||
cd $(dirname $0)
|
||||
# add PHP_VERSION to TAG, if not the default PHP version
|
||||
[ $PHP_VERSION != $DEFAULT_PHP_VERSION ] && TAG=$TAG-$PHP_VERSION
|
||||
|
||||
docker pull ubuntu:20.04
|
||||
docker build --no-cache --build-arg "VERSION=$VERSION" -t egroupware/egroupware:$TAG . && {
|
||||
docker build --no-cache --build-arg "VERSION=$VERSION" --build-arg "PHP_VERSION=$PHP_VERSION" -t egroupware/egroupware:$TAG . && {
|
||||
docker push egroupware/egroupware:$TAG
|
||||
# further tags are only for the default PHP version
|
||||
[ $PHP_VERSION != $DEFAULT_PHP_VERSION ] && exit
|
||||
# tag only stable releases as latest
|
||||
#[ $TAG != "master" ] && {
|
||||
# docker tag egroupware/egroupware:$TAG egroupware/egroupware:latest
|
||||
# docker push egroupware/egroupware:latest
|
||||
#}
|
||||
[ $TAG != "master" ] && {
|
||||
docker tag egroupware/egroupware:$TAG egroupware/egroupware:latest
|
||||
docker push egroupware/egroupware:latest
|
||||
}
|
||||
[ "$BRANCH" != $VERSION -a "${BRANCH}.x-dev" != $VERSION ] && {
|
||||
docker tag egroupware/egroupware:$VERSION egroupware/egroupware:$BRANCH
|
||||
docker tag egroupware/egroupware:$TAG egroupware/egroupware:$BRANCH
|
||||
docker push egroupware/egroupware:$BRANCH
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user