Add git-pull functionality 💅

This commit is contained in:
3wc
2022-03-23 11:57:26 +02:00
parent b8dec9d61a
commit 2158fa1fc4
4 changed files with 43 additions and 0 deletions

11
entrypoint.git-pull.sh Normal file
View File

@ -0,0 +1,11 @@
#!/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