From 8857f000a9cfa0ac6c7d9346b7177892c2e4e32e Mon Sep 17 00:00:00 2001 From: garciadeblas Date: Mon, 19 Mar 2018 14:42:49 +0100 Subject: [PATCH] gen-lxdimages: changing permissions to lxd image files; adding rsync options Change-Id: I0e1621ce679de00d18e4862f14b3e467cef99c46 Signed-off-by: garciadeblas --- tools/gen-lxdimages.sh | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/tools/gen-lxdimages.sh b/tools/gen-lxdimages.sh index f3a639ca..80d7ec42 100755 --- a/tools/gen-lxdimages.sh +++ b/tools/gen-lxdimages.sh @@ -67,14 +67,15 @@ echo "Exporting images as targz" mkdir -p "${RELEASE}" #trap 'rm -rf "$RELEASE"' EXIT -[ -n "$GEN_RO" ] && lxc image export "${OSM_RO_IMAGE}" "${RELEASE}"/"${OSM_RO_IMAGE}" -[ -n "$GEN_VCA" ] && lxc image export "${OSM_VCA_IMAGE}" "${RELEASE}"/"${OSM_VCA_IMAGE}" -[ -n "$GEN_SOUI" ] && lxc image export "${OSM_SOUI_IMAGE}" "${RELEASE}"/"${OSM_SOUI_IMAGE}" -#[ -n "$GEN_MON" ] && lxc image export "${OSM_MON_IMAGE}" "${RELEASE}"/"${OSM_MON_IMAGE}" +[ -n "$GEN_RO" ] && lxc image export "${OSM_RO_IMAGE}" "${RELEASE}"/"${OSM_RO_IMAGE}" || echo "Failed to export RO" +[ -n "$GEN_VCA" ] && lxc image export "${OSM_VCA_IMAGE}" "${RELEASE}"/"${OSM_VCA_IMAGE}" || echo "Failed to export VCA" +[ -n "$GEN_SOUI" ] && lxc image export "${OSM_SOUI_IMAGE}" "${RELEASE}"/"${OSM_SOUI_IMAGE}" || echo "Failed to export SOUI" +#[ -n "$GEN_MON" ] && lxc image export "${OSM_MON_IMAGE}" "${RELEASE}"/"${OSM_MON_IMAGE}" || echo "Failed to export MON" +chmod 664 "${RELEASE}"/*.tar.gz echo "Pushing images to ETSI FTP server" RSYNC_USER_HOST=osmusers@osm-download.etsi.org -RSYNC_OPTIONS="--delete --progress" +RSYNC_OPTIONS="--delete --progress --password-file rsync.pass" rsync -avR "$RSYNC_OPTIONS" "$RELEASE" rsync://$RSYNC_USER_HOST/repos/osm/lxd -- 2.25.1