diff --git a/mkimg.sh b/mkimg.sh index be5369c..bd1a35d 100755 --- a/mkimg.sh +++ b/mkimg.sh @@ -4,6 +4,9 @@ set -e set -x # modprobe fuse arch=$1 +[ -z $arch ] && arch=amd64 +tag=$2 +[ -z $tag ] && tag=latest # download the appimagetools echo "Downloading the appimage tools" archname=x86_64 @@ -22,21 +25,16 @@ case $arch in exit 1 ;; esac - -wget --no-check-certificate -O appimagetool.AppImage https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-$archname.AppImage +[ -f appimagetool.AppImage ] || wget --no-check-certificate -O appimagetool.AppImage https://github.com/AppImage/AppImageKit/releases/download/continuous/appimagetool-x86_64.AppImage chmod +x appimagetool.AppImage -file appimagetool.AppImage +wget --no-check-certificate https://github.com/AppImage/AppImageKit/releases/download/continuous/runtime-$archname + W="/var/jenkins_home/workspace/nightly-antosaio/build/" [ -d antos.AppDir ] && rm -rf antos.AppDir - -[ -z $arch ] && arch=amd64 -tag=$2 -[ -z $tag ] && tag=latest - echo "Building app image for $arch" mkdir antos.AppDir @@ -85,8 +83,4 @@ ln -sf /tmp/.antos_pkgcache antos.AppDir/opt/www/htdocs/os/packages/packages.jso tree antos.AppDir -./appimagetool.AppImage --appimage-extract -./squashfs-root/AppRun antos.AppDir build/AntOS_$archname-$tag.AppImage -# clean up -rm -rf squashfs-root -rm appimagetool.AppImage \ No newline at end of file +./appimagetool.AppImage --runtime-file runtime-$archname antos.AppDir build/AntOS_$archname-$tag.AppImage