-
-
Save CLCL/115dbea5996dfdabbe03 to your computer and use it in GitHub Desktop.
JenkinsCIをyum updateすると、これのせいでworkdir以下のchownが時間掛かり過ぎる JENKINS_INSTALL_SKIP_CHOWNの変数で制御できるのかな今度試す
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/sbin/chkconfig --add jenkins | |
# If we have an old hudson install, rename it to jenkins | |
if test -d /var/lib/hudson; then | |
# leave a marker to indicate this came from Hudson. | |
# could be useful down the road | |
# This also ensures that the .??* wildcard matches something | |
touch /var/lib/hudson/.moving-hudson | |
mv -f /var/lib/hudson/* /var/lib/hudson/.??* /var/lib/jenkins | |
rmdir /var/lib/hudson | |
find /var/lib/jenkins -user hudson -exec chown jenkins {} + || true | |
fi | |
if test -d /var/run/hudson; then | |
mv -f /var/run/hudson/* /var/run/jenkins | |
rmdir /var/run/hudson | |
fi | |
# Ensure the right ownership on files | |
. /etc/sysconfig/jenkins | |
if test x"$JENKINS_INSTALL_SKIP_CHOWN" != "xtrue"; then | |
chown -R ${JENKINS_USER:-jenkins} /var/cache/jenkins | |
chown -R ${JENKINS_USER:-jenkins} /var/log/jenkins | |
chown -R ${JENKINS_USER:-jenkins} ${JENKINS_HOME:-/var/lib/jenkins} | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment