mirror of
https://github.com/0xJacky/nginx-ui.git
synced 2025-05-11 18:35:51 +02:00
feat(wip): docker ui only
This commit is contained in:
parent
c62fd25b2e
commit
d4a4ed1e1c
43 changed files with 1269 additions and 372 deletions
|
@ -37,15 +37,22 @@ func Save(name string, content string, overwrite bool, syncNodeIds []uint64, pos
|
|||
|
||||
enabledConfigFilePath := nginx.GetConfPath("streams-enabled", name)
|
||||
if helper.FileExists(enabledConfigFilePath) {
|
||||
var output string
|
||||
// Test nginx configuration
|
||||
output := nginx.TestConf()
|
||||
output, err = nginx.TestConfig()
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
if nginx.GetLogLevel(output) > nginx.Warn {
|
||||
return cosy.WrapErrorWithParams(ErrNginxTestFailed, output)
|
||||
}
|
||||
|
||||
if postAction == model.PostSyncActionReloadNginx {
|
||||
output = nginx.Reload()
|
||||
output, err = nginx.Reload()
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
if nginx.GetLogLevel(output) > nginx.Warn {
|
||||
return cosy.WrapErrorWithParams(ErrNginxReloadFailed, output)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue