Support multi-architecture containers.
[lgpl/argeo-commons.git] / dist / containers / argeo2-node
index 839d3cdb5d4d975707697fc6a8507a475435ceeb..8578ab94a658fe5108547d73933d8cd37ec2a6ed 100755 (executable)
@@ -1,17 +1,16 @@
 #!/bin/sh
 
 source "$(dirname "$0")/buildah-metadata"
-container=$(buildah from argeo/argeo2-tp:$VERSION_ARGEO_TP)
+container=$(buildah from argeo/argeo2-tp:$VERSION_ARGEO_TP-$ARCH)
 
 # Override version
-VERSION=2.1.84
 #buildah copy $container argeo2-rpmfactory.repo /etc/yum.repos.d/
 #buildah copy $container /srv/rpmfactory/argeo-osgi-2/el7/ /srv/rpmfactory/argeo-osgi-2/el7/
 
 source "$(dirname "$0")/buildah-common"
 
 buildah config --label release="1" $container
-buildah config --label version="$VERSION" $container
+buildah config --label version="$VERSION_ARGEO_COMMONS" $container
 
 # Metadata
 buildah config --label name="argeo2-node" $container
@@ -28,7 +27,8 @@ buildah run $container -- microdnf clean all
 buildah config --entrypoint '["/usr/sbin/argeoctl","start"]' $container
 buildah config --port 8080 $container
 
-buildah commit --rm --format docker $container argeo/argeo2-node:$VERSION
-buildah tag argeo/argeo2-node:$VERSION argeo/argeo2-node:latest
-buildah push argeo/argeo2-node:$VERSION docker://argeo/argeo2-node:$VERSION
-buildah push argeo/argeo2-node:$VERSION docker://argeo/argeo2-node:latest
+buildah commit --rm --format docker $container argeo/argeo2-node:$VERSION_ARGEO_COMMONS-$ARCH
+buildah tag argeo/argeo2-node:$VERSION_ARGEO_COMMONS-$ARCH argeo/argeo2-node:$ARCH
+
+buildah push argeo/argeo2-node:$VERSION_ARGEO_COMMONS-$ARCH docker://argeo/argeo2-node:$VERSION_ARGEO_COMMONS-$ARCH
+buildah push argeo/argeo2-node:$ARCH docker://argeo/argeo2-node:$ARCH