Browse Source

Don't create a default pid file (#637)

tags/v1.21.12.1
Bwko Lunny Xiao 8 years ago
parent
commit
4a1f36c3cc
2 changed files with 3 additions and 5 deletions
  1. +1
    -1
      cmd/web.go
  2. +2
    -4
      modules/setting/setting.go

+ 1
- 1
cmd/web.go View File

@@ -62,7 +62,7 @@ and it takes care of all the other things for you`,
}, },
cli.StringFlag{ cli.StringFlag{
Name: "pid, P", Name: "pid, P",
Value: "custom/run/app.pid",
Value: "/var/run/gitea.pid",
Usage: "Custom pid file path", Usage: "Custom pid file path",
}, },
}, },


+ 2
- 4
modules/setting/setting.go View File

@@ -515,12 +515,10 @@ please consider changing to GITEA_CUSTOM`)
} }
} }


if len(CustomPID) == 0 {
CustomPID = CustomPath + "/run/app.pid"
if len(CustomPID) > 0 {
createPIDFile(CustomPID)
} }


createPIDFile(CustomPID)

if len(CustomConf) == 0 { if len(CustomConf) == 0 {
CustomConf = CustomPath + "/conf/app.ini" CustomConf = CustomPath + "/conf/app.ini"
} }


Loading…
Cancel
Save