Skip to content

Instantly share code, notes, and snippets.



Created Jan 16, 2012
What would you like to do?
jenkins をOS X のログインユーザー権限のデーモンで自動起動しておく設定
launchctl load -wF -D user ~/Library/LaunchAgents/jenkins.plist
launchctl list | grep jenkins
# 58066 - jenkins
launchctl start jenkins
open http://localhost:8080/
# Startup script used by Jenkins launchd job.
# Mac OS X launchd process calls this script to customize
# the java process command line used to run Jenkins.
# Customizable parameters are found in
# ~/Library/Preferences/jenkins.plist
# You can manipulate it using the "defaults" utility.
# See "man defaults" for details.
defaults="defaults read ~/Library/Preferences/jenkins"
war=`$defaults war` || war="${HOME}/lib/java/jenkins.war"
heapSize=`$defaults heapSize` && javaArgs="$javaArgs -Xmx${heapSize}"
home=`$defaults JENKINS_HOME` && export JENKINS_HOME="$home"
add_to_args() {
val=`$defaults $1` && args="$args --${1}=${val}"
add_to_args prefix
add_to_args httpPort
add_to_args httpListenAddress
add_to_args httpsPort
add_to_args httpsListenAddress
add_to_args ajp13Port
add_to_args ajp13ListenAddress
echo "Jenkins command line for execution:"
echo /usr/bin/java $javaArgs -jar "$war" $args
exec /usr/bin/java $javaArgs -jar "$war" $args
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment