Add 'init/entrypoint.sh'

This commit is contained in:
Danny Bessems 2020-02-17 12:40:01 +00:00
parent fe30c811ca
commit 4980ac6405
1 changed files with 13 additions and 0 deletions

13
init/entrypoint.sh Normal file
View File

@ -0,0 +1,13 @@
#!/bin/sh
# Clone git-repo
git init
git config core.sparsecheckout true
echo $SPARSE_CHECKOUT >> .git/info/sparse-checkout
git remote add -f origin $REMOTE_REPO
git pull origin $REMOTE_BRANCH
mkdir -p /app/$COMPONENT/scripts
mv ./components/*/**/* /app/$COMPONENT/scripts
exec "$@"