Remove full kibanaurl from rest api

This commit is contained in:
Brandon Myers 2019-05-13 17:34:30 -05:00
Родитель 2c7181ccc8
Коммит 5f9ccef547
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 8AA79AD83045BBC7
9 изменённых файлов: 6 добавлений и 17 удалений

Просмотреть файл

@ -122,7 +122,6 @@ Resources:
# Drives the configuration of variables for a variety of containers.
OPTIONS_ESSERVERS=${ESURL}
OPTIONS_KIBANAURL=${KibanaURL}
OPTIONS_METEOR_KIBANAURL=$OPTIONS_KIBANAURL
OPTIONS_METEOR_ROOTURL=https://${DomainName}
# See https://github.com/mozilla-iam/mozilla.oidc.accessproxy/blob/master/README.md#setup
# Future support will be added for cognito backed authentication.

Просмотреть файл

@ -1,5 +1,4 @@
[options]
kibanaurl=http://localhost:9090/app/kibana
esservers=http://elasticsearch:9200
mongohost=mongodb
mongoport=3002

Просмотреть файл

@ -25,7 +25,7 @@ Certain environment variables have special meaning to the web ui (meteor):
OPTIONS_METEOR_ROOTURL is "http://localhost" by default and should be set to the dns name of the UI where you will run MozDef
OPTIONS_METEOR_PORT is 80 by default and is the port on which the UI will run
OPTIONS_METEOR_ROOTAPI is http://rest:8081 by default and should resolve to the location of the rest api
OPTIONS_METEOR_KIBANAURL is http://localhost:9090/app/kibana# by default and should resolve to your kibana installation
OPTIONS_KIBANAURL is http://localhost:9090/app/kibana# by default and should resolve to your kibana installation
OPTIONS_METEOR_ENABLECLIENTACCOUNTCREATION is true by default and governs whether accounts can be created
OPTIONS_METEOR_AUTHENTICATIONTYPE is meteor-password by default and can be set to oidc to allow for oidc authentication
OPTIONS_REMOVE_FEATURES is empty by default, but if you pass a comma separated list of features you'd like to remove they will no longer be available.

Просмотреть файл

@ -94,7 +94,7 @@ Copyright (c) 2014 Mozilla Corporation
<template name="kibanaDashboardItem">
<li>
<a target=" _blank" href="{{url}}">{{name}}</a>
<a target=" _blank" href="{{ mozdef.kibanaURL }}#/dashboard/{{id}}">{{name}}</a>
</li>
</template>

Просмотреть файл

@ -20,7 +20,7 @@ if (Meteor.isServer) {
rootURL: process.env.OPTIONS_METEOR_ROOTURL || "http://localhost",
port: process.env.OPTIONS_METEOR_PORT || "80",
rootAPI: process.env.OPTIONS_METEOR_ROOTAPI || "http://rest:8081",
kibanaURL: process.env.OPTIONS_METEOR_KIBANAURL || "http://localhost:9090/app/kibana",
kibanaURL: process.env.OPTIONS_KIBANAURL || "http://localhost:9090/app/kibana",
enableClientAccountCreation: allowAccountCreation,
authenticationType: process.env.OPTIONS_METEOR_AUTHENTICATIONTYPE || "meteor-password",
removeFeatures: process.env.OPTIONS_REMOVE_FEATURES || ""

Просмотреть файл

@ -1,5 +1,4 @@
[options]
kibanaurl=http://localhost:9090/app/kibana
esservers=http://localhost:9200
mongoport=3002
listen_host=0.0.0.0

Просмотреть файл

@ -527,11 +527,7 @@ def kibanaDashboards():
for dashboard in results['hits']:
resultsList.append({
'name': dashboard['_source']['title'],
'url': "%s#/%s/%s" % (
options.kibanaurl,
"dashboard",
dashboard['_id']
)
'id': dashboard['_id']
})
except ElasticsearchInvalidIndex as e:
@ -627,9 +623,6 @@ def initConfig():
options.esservers = list(getConfig('esservers',
'http://localhost:9200',
options.configfile).split(','))
options.kibanaurl = getConfig('kibanaurl',
'http://localhost:9090',
options.configfile)
# mongo connectivity options
options.mongohost = getConfig('mongohost', 'localhost', options.configfile)

Просмотреть файл

@ -1,5 +1,4 @@
[options]
kibanaurl=http://localhost:9090/app/kibana
esservers=http://localhost:9200
mongoport=3002
listen_host=0.0.0.0

Просмотреть файл

@ -63,10 +63,10 @@ class TestKibanaDashboardsRoute(RestTestSuite):
json_resp.sort()
assert json_resp[1]['url'].endswith("/app/kibana#/dashboard/Example-SSH-Dashboard") is True
assert json_resp[1]['id'] == "Example-SSH-Dashboard"
assert json_resp[1]['name'] == 'Example SSH Dashboard'
assert json_resp[0]['url'].endswith("/app/kibana#/dashboard/Example-FTP-Dashboard") is True
assert json_resp[0]['id'] == "Example-FTP-Dashboard"
assert json_resp[0]['name'] == 'Example FTP Dashboard'