mirror of
https://github.com/lucky-sideburn/kubeinvaders.git
synced 2026-04-17 23:56:34 +00:00
fix html
This commit is contained in:
@@ -213,7 +213,7 @@ function setRedisLogRegex() {
|
||||
|
||||
if (log_tail_switch) {
|
||||
var oReq = new XMLHttpRequest();
|
||||
oReq.open("GET", "https://" + clu_endpoint + "/kube/chaos/containers?action=disabled_logs_tail", true);
|
||||
oReq.open("GET", "https://" + clu_endpoint + "/kube/chaos/containers?action=disable_logs_tail", true);
|
||||
|
||||
oReq.onreadystatechange = function () {
|
||||
if (this.readyState === XMLHttpRequest.DONE && this.status === 200) {
|
||||
@@ -225,7 +225,7 @@ function setRedisLogRegex() {
|
||||
|
||||
} else {
|
||||
var oReq = new XMLHttpRequest();
|
||||
oReq.open("POST", "https://" + clu_endpoint + "/kube/chaos/containers?action=enabled_logs_tail", true);
|
||||
oReq.open("POST", "https://" + clu_endpoint + "/kube/chaos/containers?action=enable_logs_tail", true);
|
||||
|
||||
oReq.onreadystatechange = function () {
|
||||
if (this.readyState === XMLHttpRequest.DONE && this.status === 200) {
|
||||
|
||||
@@ -33,13 +33,13 @@ elseif ngx.var.request_method == "POST" and action == 'set' then
|
||||
red:set("chaos_container", body_data)
|
||||
ngx.say("New chaos container definition has been configured in Redis")
|
||||
return ngx.exit(ngx.status)
|
||||
elseif ngx.var.request_method == "POST" and action == "enabled_logs_tail" then
|
||||
elseif ngx.var.request_method == "POST" and action == "enable_logs_tail" then
|
||||
local body_data = ngx.req.get_body_data()
|
||||
red:set("log_pod_regex", body_data)
|
||||
red:set("logs_enabled", "1")
|
||||
ngx.say("New container definition has been saved in Redis")
|
||||
return ngx.exit(ngx.status)
|
||||
elseif ngx.var.request_method == "POST" and action == "disabled_logs_tail" then
|
||||
elseif ngx.var.request_method == "GET" and action == "disable_logs_tail" then
|
||||
red:set("logs_enabled", "0")
|
||||
ngx.say("New container definition has been saved in Redis")
|
||||
return ngx.exit(ngx.status)
|
||||
|
||||
Reference in New Issue
Block a user