Skip to content
Snippets Groups Projects
Commit 1cd2c442 authored by jurgenhaas's avatar jurgenhaas
Browse files

#15 Fix minor issues in selfupdate

parent 5882f39e
No related branches found
No related tags found
No related merge requests found
#!/bin/sh
#!/bin/bash
if [[ -n $1 ]]; then
NEWVERSION=$1
......@@ -8,15 +8,16 @@ fi
if [[ "$NEWVERSION" == "$VERSION" ]]; then
echo "No new version available"
return
exit
fi
UPDATE=$(docker run -v ${SCRIPTPATH}:/setup --rm registry.lakedrops.com/docker/l3d/setup:${NEWVERSION})
echo "Loading new version ..."
UPDATE=$(docker run -v ${SCRIPTPATH}:/setup --rm registry.lakedrops.com/docker/l3d/setup:${NEWVERSION} 2>&1)
if [[ "$UPDATE" == *"setup:${NEWVERSION} not found"* ]]; then
echo "Version not found."
return
echo "Version ${NEWVERSION} not found."
exit
fi
echo "Self update succeeded!"
echo "Self update to versino ${NEWVERSION} succeeded!"
echo "Cleaning old container"
docker stop l3dsetup
docker stop l3drun
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment