seafile build image : deriver la branche de la version
This commit is contained in:
parent
339d917d17
commit
7550ff636f
|
@ -12,12 +12,12 @@ buildfolder=/tmp/seafile-$$
|
||||||
if ! podman image exists ${seafile_image}:${seafile_release}; then
|
if ! podman image exists ${seafile_image}:${seafile_release}; then
|
||||||
mkdir ${buildfolder} &&
|
mkdir ${buildfolder} &&
|
||||||
git clone --depth=1 https://github.com/haiwen/seafile-docker.git ${buildfolder}/ &&
|
git clone --depth=1 https://github.com/haiwen/seafile-docker.git ${buildfolder}/ &&
|
||||||
sed_in_place "^FROM phusion/baseimage:focal-1.0.0" "FROM docker.io/phusion/baseimage:focal-1.0.0" ${buildfolder}/image/seafile_9.0/Dockerfile &&
|
sed_in_place "^FROM phusion/baseimage:focal-1.0.0" "FROM docker.io/phusion/baseimage:focal-1.0.0" ${buildfolder}/image/seafile_${seafile_release%.*}/Dockerfile &&
|
||||||
sed_in_place "SEAFILE_VERSION=" "SEAFILE_VERSION=${seafile_release}" ${buildfolder}/image/seafile_9.0/Dockerfile &&
|
sed_in_place "SEAFILE_VERSION=" "SEAFILE_VERSION=${seafile_release}" ${buildfolder}/image/seafile_${seafile_release%.*}/Dockerfile &&
|
||||||
mv ${buildfolder}/scripts_9.0 ${buildfolder}/image/seafile_9.0/ &&
|
mv ${buildfolder}/scripts_${seafile_release%.*} ${buildfolder}/image/seafile_${seafile_release%.*}/ &&
|
||||||
podman build -t ${seafile_image}:${seafile_release} \
|
podman build -t ${seafile_image}:${seafile_release} \
|
||||||
-f ${buildfolder}/image/seafile_9.0/Dockerfile \
|
-f ${buildfolder}/image/seafile_${seafile_release%.*}/Dockerfile \
|
||||||
${buildfolder}/image/seafile_9.0 &&
|
${buildfolder}/image/seafile_${seafile_release%.*} &&
|
||||||
podman rmi phusion/baseimage:focal-1.0.0
|
podman rmi phusion/baseimage:focal-1.0.0
|
||||||
rm -rf ${buildfolder}
|
rm -rf ${buildfolder}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in a new issue