2021-05-04 20:28:54 +00:00
|
|
|
#!/usr/bin/env bash
|
|
|
|
|
|
|
|
ABSDIR="$( dirname "$(readlink -f -- "$0")" )"
|
|
|
|
source ${ABSDIR}/../functions.sh
|
|
|
|
source ${ABSDIR}/vars.sh
|
|
|
|
|
|
|
|
ensure_pwd_is_scriptdir
|
|
|
|
ensure_not_root
|
|
|
|
|
2021-06-04 08:52:34 +00:00
|
|
|
|
|
|
|
upstream_image='docker.io/peerjs/peerjs-server'
|
|
|
|
upstream_version='0.6.1'
|
|
|
|
upstream_imageversion=${upstream_image}:${container_name}
|
|
|
|
current_imageversion=$(podman container inspect -f '{{.ImageName}}' ${container_name})
|
|
|
|
|
|
|
|
if [[ "${upstream_imageversion}" != "${current_imageversion}" ]] ; then
|
|
|
|
echo Container ${container_name} needs to be rebuilt
|
|
|
|
echo NOT IMPLEMENTED YET
|
|
|
|
exit 1
|
|
|
|
else
|
|
|
|
echo Container ${container_name} does not needs rebuilding. Exiting
|
|
|
|
exit 0
|
|
|
|
fi
|
|
|
|
|