Files
kiwix-build/travis/deploy.sh
Matthieu Gautier cab89b38c0 Publish intermediate dependencies in a http accessible directory.
Those dependencies will be used by travis CI in other projects.
We want to avoid other project to need a ssh key to get them :
- To avoid spread(and maintenance) of ssh key.
- For PR coming from another repositories, ssh key is not available.

By making those dependencies available by http, we simplify the process.

Fix partially #34.
Archives download need to be updated in client projects.
2017-04-18 11:07:46 +02:00

25 lines
599 B
Bash
Executable File

#!/usr/bin/env bash
set -e
DEPS_ARCHIVES_DIR=${HOME}/DEPS_ARCHIVES
NIGHTLY_ARCHIVES_DIR=${HOME}/NIGHTLY_ARCHIVES
SSH_KEY=travis/travisci_builder_id_key
DEPS_ARCHIVES=$(find $DEPS_ARCHIVES_DIR -type f)
if [[ "x$DEPS_ARCHIVES" != "x" ]]
then
scp -vp -i ${SSH_KEY} \
${DEPS_ARCHIVES} \
nightlybot@download.kiwix.org:/var/www/tmp.kiwix.org/ci/
fi
NIGHTLY_ARCHIVES=$(find $NIGHTLY_ARCHIVES_DIR -type f)
if [[ "x$NIGHTLY_ARCHIVES" != "x" ]]
then
scp -vrp -i ${SSH_KEY} \
${NIGHTLY_ARCHIVES} \
nightlybot@download.kiwix.org:/var/www/download.kiwix.org/nightly/$(date +%Y-%m-%d)
fi