From 995718cd02c1d3bb4cdb630234a63eacc243ede8 Mon Sep 17 00:00:00 2001 From: Julien Cabillot Date: Tue, 31 Oct 2017 13:23:13 +0000 Subject: [PATCH] Add new file --- update.sh | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 update.sh diff --git a/update.sh b/update.sh new file mode 100644 index 0000000..5042e0e --- /dev/null +++ b/update.sh @@ -0,0 +1,28 @@ +#!/usr/bin/env bash + +set -o pipefail -o nounset -o errexit + +REPO="ssh://git@gitlab.cabillot.eu:2224/www/dl.git" +REPO2="https://github.com/blueimp/jQuery-File-Upload.git" +TAG="registry.cabillot.eu/www/dl" + +( + if [[ ! -d "build/" ]] + then + git clone "${REPO2}" "build/" + fi + + cd "build/" + git pull + + if [[ ! -d "src" ]] + then + git clone "${REPO2}" "src" + fi + + cd "src" + git pull +) + +#docker build --no-cache=true -t "${TAG}" build/ +#docker push "${TAG}" \ No newline at end of file