Commit a63c0051 authored by godog's avatar godog

Trim kibana url madness

Leave the _g hash untouched and trim _a with only a few parameters,
notably the lucene query to search for "FQDN*". The wildcard is used to
match both fqdn and "related" that might appear in logs such as
fqdn:port or fqdn/.
parent 181dd465
Pipeline #1440 passed with stages
in 37 seconds
......@@ -46,12 +46,10 @@ func (p PublicEndpoint) URL() string {
func (p PublicEndpoint) LogsURL() template.HTML {
// Woah.
return template.HTML(fmt.Sprintf(
"https://logs.%s/app/kibana#/dashboard/%s?_g=(refreshInterval:(display:Off,pause:!f,value:0),time:(from:now-12h,mode:quick,to:now))&_a=(description:'',filters:!(('$state':(store:appState),meta:(alias:!n,disabled:!f,index:da92a2d0-55fd-11e8-b43b-036ee7010221,key:vhost,negate:!f,params:(query:'%s:443',type:phrase),type:phrase,value:'%s:443'),query:(match:(vhost:(query:'%s:443',type:phrase))))),fullScreenMode:!f,options:(darkTheme:!f,useMargins:!f),panels:!((gridData:(h:15,i:'3',w:32,x:0,y:0),id:AWBcpcqhmhRvefO8Fqke,panelIndex:'3',type:visualization,version:'6.3.2'),(gridData:(h:15,i:'4',w:24,x:0,y:15),id:AWBcn9temhRvefO8Fkhj,panelIndex:'4',type:visualization,version:'6.3.2'),(embeddableConfig:(vis:(legendOpen:!t)),gridData:(h:15,i:'6',w:16,x:32,y:0),id:AWBh8jIzmhRvefO8gLxW,panelIndex:'6',type:visualization,version:'6.3.2'),(gridData:(h:15,i:'9',w:24,x:24,y:15),id:'6ddaf180-5614-11e8-b43b-036ee7010221',panelIndex:'9',type:visualization,version:'6.3.2'),(gridData:(h:40,i:'10',w:48,x:0,y:30),id:'1e7053a0-5615-11e8-b43b-036ee7010221',panelIndex:'10',type:search,version:'6.3.2')),query:(language:lucene,query:(match_all:())),timeRestore:!f,title:'web:%20overview',viewMode:view)",
"https://logs.%s/app/kibana#/dashboard/%s?_g=(refreshInterval:(display:Off,pause:!f,value:0),time:(from:now-12h,mode:quick,to:now))&_a=(description:'',filters:!(),query:(language:lucene,query:'%s*'))",
config.PublicDomain,
kibanaWebDashboardID,
p.FQDN(),
p.FQDN(),
p.FQDN(),
))
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment