Fix the service file so it should work from startup
This commit is contained in:
parent
b9d3043407
commit
9b8ad465d7
|
@ -3,7 +3,8 @@ Description=My main HTTP server
|
||||||
After=network.target syslog.target
|
After=network.target syslog.target
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=oneshot
|
Type=forking
|
||||||
|
PIDFile=/tmp/kelvinly-server-pid
|
||||||
ExecStart=/home/kelvin/kelvinly-server/kelvinly-server
|
ExecStart=/home/kelvin/kelvinly-server/kelvinly-server
|
||||||
StandardOutput=syslog
|
StandardOutput=syslog
|
||||||
StandardError=syslog
|
StandardError=syslog
|
||||||
|
|
2
main.go
2
main.go
|
@ -99,7 +99,7 @@ func main() {
|
||||||
PidFilePerm: 0644,
|
PidFilePerm: 0644,
|
||||||
LogFileName: "/tmp/kelvinly-server-log",
|
LogFileName: "/tmp/kelvinly-server-log",
|
||||||
LogFilePerm: 0640,
|
LogFilePerm: 0640,
|
||||||
WorkDir: "./",
|
WorkDir: "/home/kelvin/kelvinly-server/",
|
||||||
Umask: 027,
|
Umask: 027,
|
||||||
}
|
}
|
||||||
// TODO: figure out the daemonizing stuff
|
// TODO: figure out the daemonizing stuff
|
||||||
|
|
Loading…
Reference in New Issue