Hedgedoc : 1.9.7 + passage a buildkit
This commit is contained in:
parent
137e471001
commit
188b3b9af1
|
@ -12,8 +12,19 @@ buildfolder=/tmp/hedgedoc-$$
|
||||||
if ! podman image exists ${hedgedoc_image}:${hedgedoc_version}; then
|
if ! podman image exists ${hedgedoc_image}:${hedgedoc_version}; then
|
||||||
mkdir ${buildfolder} &&
|
mkdir ${buildfolder} &&
|
||||||
git clone --depth=1 https://github.com/hedgedoc/container ${buildfolder}/ && {
|
git clone --depth=1 https://github.com/hedgedoc/container ${buildfolder}/ && {
|
||||||
|
sed_in_place '^FROM --platform=$BUILDPLATFORM node' 'FROM --platform=$BUILDPLATFORM docker.io/library/node' ${buildfolder}/alpine/Dockerfile
|
||||||
sed_in_place "^FROM node" "FROM docker.io/library/node" ${buildfolder}/alpine/Dockerfile
|
sed_in_place "^FROM node" "FROM docker.io/library/node" ${buildfolder}/alpine/Dockerfile
|
||||||
TMPDIR=${HOME} podman image build -t ${hedgedoc_image}:${hedgedoc_version} --build-arg VERSION=${hedgedoc_version/%-alpine/} -f ${buildfolder}/alpine/Dockerfile ${buildfolder}
|
podman pull docker.io/moby/buildkit:latest
|
||||||
|
podman run -d --name buildkitd --privileged docker.io/moby/buildkit:latest &&
|
||||||
|
my_buildctl --addr=podman-container://buildkitd build \
|
||||||
|
--frontend dockerfile.v0 \
|
||||||
|
--opt build-arg:VERSION=${hedgedoc_version/%-alpine/} \
|
||||||
|
--local context=${buildfolder}/ \
|
||||||
|
--local dockerfile=${buildfolder}/alpine/ \
|
||||||
|
--output type=oci,name="${hedgedoc_image}:${hedgedoc_version}" | \
|
||||||
|
podman load &&
|
||||||
|
podman rm --force buildkitd &&
|
||||||
|
podman rmi docker.io/moby/buildkit:latest
|
||||||
}
|
}
|
||||||
rm -rf ${buildfolder}
|
rm -rf ${buildfolder}
|
||||||
podman image prune -a -f --filter dangling=true
|
podman image prune -a -f --filter dangling=true
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
## vars
|
## vars
|
||||||
#hedgedoc_image="quay.io/hedgedoc/hedgedoc"
|
#hedgedoc_image="quay.io/hedgedoc/hedgedoc"
|
||||||
hedgedoc_image="git.garbaye.fr/garbaye/hedgedoc"
|
hedgedoc_image="git.garbaye.fr/garbaye/hedgedoc"
|
||||||
hedgedoc_version='1.9.6-alpine'
|
hedgedoc_version='1.9.7-alpine'
|
||||||
database_image="docker.io/library/postgres"
|
database_image="docker.io/library/postgres"
|
||||||
database_version='14.5-alpine'
|
database_version='14.5-alpine'
|
||||||
database_path="/var/lib/postgresql/data"
|
database_path="/var/lib/postgresql/data"
|
||||||
|
|
Loading…
Reference in a new issue