-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathbf1942.conf
More file actions
32 lines (25 loc) · 702 Bytes
/
Copy pathbf1942.conf
File metadata and controls
32 lines (25 loc) · 702 Bytes
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
# battlefield 1942 upstart script
description "start and stop battlefield 1942 server"
version "0.1"
author "Chris Grimmett <chris@grimtech.net>"
# config
env BF1942_HOME=/srv
env BF1942_PORT=145678
env BF1942_HOST=0.0.0.0
env BF1942_EXEC=$BF1942_HOME/start
# tell upstart we're creating a daemon
expect fork
# start when filesystems and network device are up,
# stop when powering down or rebooting
start on (local-filesystems and net-device-up)
stop on runlevel [!2345]
pre-start script
#cd $BF1942_HOME
#exec /usr/bin/bash $BF1942_EXEC
#emit bf1942_starting
end script
script
cd $BF1942_HOME
exec bin/bash $BF1942_EXEC $BF1942_HOST:$BF1942_PORT &
emit bf1942_running
end script