enhance: nginx control

This commit is contained in:
0xJacky 2023-12-06 22:56:36 +08:00
parent 30f75ff7cd
commit f7d9f2564f
No known key found for this signature in database
GPG key ID: B6E4A6E4A561BAF0
8 changed files with 131 additions and 69 deletions

View file

@ -51,7 +51,7 @@ func FormatNginxConfig(c *gin.Context) {
}
func Status(c *gin.Context) {
pidPath := nginx.GetNginxPIDPath()
pidPath := nginx.GetPIDPath()
running := true
if fileInfo, err := os.Stat(pidPath); err != nil || fileInfo.Size() == 0 { // fileInfo.Size() == 0 no process id

View file

@ -14,5 +14,5 @@ func InitRouter(r *gin.RouterGroup) {
}
func InitNginxLogRouter(r *gin.RouterGroup) {
r.GET("nginx_log", NginxLog)
r.GET("nginx_log", Log)
}