2010-08-10 10:12:52 +02:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
# gitolite mirroring
|
|
|
|
|
|
|
|
# please see doc/mirroring.mkd for instructions on how to use this
|
|
|
|
|
|
|
|
if [ -n "$GL_SLAVES" ]
|
|
|
|
then
|
|
|
|
for mirror in $GL_SLAVES
|
|
|
|
do
|
|
|
|
if git push --mirror $mirror:$GL_REPO.git
|
|
|
|
then
|
|
|
|
:
|
|
|
|
else
|
|
|
|
ssh $mirror mkdir -p $GL_REPO.git
|
|
|
|
ssh $mirror git init --bare $GL_REPO.git
|
2010-10-26 15:56:31 +02:00
|
|
|
ssh $mirror git config receive.fsckObjects true
|
2010-08-10 10:12:52 +02:00
|
|
|
git push --mirror $mirror:$GL_REPO.git ||
|
|
|
|
echo "WARNING: mirror push to $mirror failed"
|
|
|
|
fi
|
|
|
|
done
|
|
|
|
fi >&2
|