custom-html/entrypoint.git-pull.sh

12 lines
213 B
Bash
Raw Normal View History

2022-03-23 09:57:26 +00:00
#!/bin/sh
if [ ! -d /git/.git ]; then
echo "No repo found, emptying /git/ directory"
rm -r /git/*
echo "Cloning $GIT_REPO_URL into /git"
git clone "$GIT_REPO_URL" /git
else
echo "Updating /git"
git pull
fi