Sergey Kraynev 0812b03d57 Move all *.sh and *.pp files to scripts directories
Change-Id: I15bd9e9da742ec3f99574316fa0ec82c2608f0ec
2016-07-21 11:03:48 +03:00

16 lines
390 B
Bash
Executable File

#!/usr/bin/env bash
cd /etc/project-config
# Check for new changes.
su zuul -c "git pull"
sha_from_repo=$(sha1sum zuul/layout.yaml | awk '{print $1}')
sha_local=$(sha1sum /etc/zuul/layout/layout.yaml | awk '{print $1}')
# Determine whether a change is made.
if [ "$sha_local" != "$sha_from_repo" ]; then
cp zuul/layout.yaml /etc/zuul/layout/layout.yaml
service zuul force-reload
fi