#!/bin/sh # /etc/init.d/teamcity - startup script for teamcity export TEAMCITY_DATA_PATH="{{ pillar['homedir'] }}/local/TeamCity-{{ pillar['versions']['teamcity'] }}/.BuildServer" /etc/profile.d/java.sh case $1 in start) start-stop-daemon --start -c {{ pillar['username'] }} --exec {{ pillar['homedir'] }}/local/TeamCity-{{ pillar['versions']['teamcity'] }}/bin/runAll.sh start ;; stop) start-stop-daemon --start -c {{ pillar['username'] }} --exec {{ pillar['homedir'] }}/local/TeamCity-{{ pillar['versions']['teamcity'] }}/bin/runAll.sh stop ;; esac exit 0