-
Notifications
You must be signed in to change notification settings - Fork 166
/
Copy pathaix.rc2.j2
32 lines (30 loc) · 1.13 KB
/
aix.rc2.j2
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/ksh
##################################################
# name: S20jenkins
# purpose: script that will start or stop jenkins
##################################################
case "$1" in
start )
su - {{server_user}} -c '\
ulimit -c 0; \
ulimit -d unlimited; \
ulimit -m unlimited; \
export TERM=ansi; \
export jenkins_log_file="/home/{{server_user}}/jenkins_console.log"; \
export HOME=/home/{{server_user}}; \
export LIBPATH=/opt/freeware/lib64:/opt/freeware/lib:/usr/lib:/lib; \
export NODE_TEST_DIR=$HOME/tmp; \
export NODE_COMMON_PIPE="$HOME/test.pipe"; \
export PATH="/opt/freeware/bin:/usr/opt/python3/bin/:$PATH"; \
export OSTYPE=AIX72; \
export JOBS={{ jobs_env }}; \
/usr/bin/java -Xmx128m -Dorg.jenkinsci.plugins.gitclient.Git.timeOut=30 -jar "$HOME/agent.jar" \
-secret {{secret}} \
-url {{jenkins_url}} -name {{inventory_hostname}} >$jenkins_log_file 2>&1 &'
;;
stop )
;;
* )
echo "Usage: $0 (start | stop)"
exit 1
esac