2018-05-29 05:06:30 +02:00
|
|
|
/*
|
|
|
|
* Licensed to Elasticsearch B.V. under one or more contributor
|
|
|
|
* license agreements. See the NOTICE file distributed with
|
|
|
|
* this work for additional information regarding copyright
|
|
|
|
* ownership. Elasticsearch B.V. licenses this file to you under
|
|
|
|
* the Apache License, Version 2.0 (the "License"); you may
|
|
|
|
* not use this file except in compliance with the License.
|
|
|
|
* You may obtain a copy of the License at
|
|
|
|
*
|
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
*
|
|
|
|
* Unless required by applicable law or agreed to in writing,
|
|
|
|
* software distributed under the License is distributed on an
|
|
|
|
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
|
|
* KIND, either express or implied. See the License for the
|
|
|
|
* specific language governing permissions and limitations
|
|
|
|
* under the License.
|
|
|
|
*/
|
|
|
|
|
2018-05-10 01:23:49 +02:00
|
|
|
import { format as formatUrl } from 'url';
|
|
|
|
import { OPTIMIZE_BUNDLE_DIR, esTestConfig, kbnTestConfig } from '@kbn/test';
|
2019-02-28 21:06:00 +01:00
|
|
|
import { services } from './services';
|
2017-05-18 03:53:45 +02:00
|
|
|
|
|
|
|
export default function () {
|
2018-05-10 01:23:49 +02:00
|
|
|
const servers = {
|
|
|
|
kibana: kbnTestConfig.getUrlParts(),
|
|
|
|
elasticsearch: esTestConfig.getUrlParts(),
|
|
|
|
};
|
|
|
|
|
2017-05-18 03:53:45 +02:00
|
|
|
return {
|
2018-05-10 01:23:49 +02:00
|
|
|
servers,
|
|
|
|
|
|
|
|
esTestCluster: {
|
|
|
|
license: 'oss',
|
|
|
|
from: 'snapshot',
|
|
|
|
serverArgs: [
|
|
|
|
],
|
2017-05-18 03:53:45 +02:00
|
|
|
},
|
2018-05-10 01:23:49 +02:00
|
|
|
|
2018-05-21 15:31:30 +02:00
|
|
|
kbnTestServer: {
|
|
|
|
buildArgs: [ '--optimize.useBundleCache=true' ],
|
|
|
|
sourceArgs: [
|
|
|
|
'--no-base-path',
|
2019-02-18 23:01:30 +01:00
|
|
|
'--env.name=development',
|
2018-05-21 15:31:30 +02:00
|
|
|
`--optimize.bundleDir=${OPTIMIZE_BUNDLE_DIR}`,
|
|
|
|
],
|
|
|
|
serverArgs: [
|
|
|
|
'--logging.json=false',
|
|
|
|
`--server.port=${kbnTestConfig.getPort()}`,
|
2018-06-05 23:10:15 +02:00
|
|
|
`--optimize.watchPort=${kbnTestConfig.getPort() + 10}`,
|
2018-05-21 15:31:30 +02:00
|
|
|
'--optimize.watchPrebuild=true',
|
|
|
|
'--status.allowAnonymous=true',
|
|
|
|
'--optimize.enabled=true',
|
2018-12-18 20:22:43 +01:00
|
|
|
`--elasticsearch.hosts=${formatUrl(servers.elasticsearch)}`,
|
2018-05-21 15:31:30 +02:00
|
|
|
`--elasticsearch.username=${servers.elasticsearch.username}`,
|
|
|
|
`--elasticsearch.password=${servers.elasticsearch.password}`,
|
2019-01-17 21:13:13 +01:00
|
|
|
`--kibana.disableWelcomeScreen=true`,
|
2019-10-16 09:24:20 +02:00
|
|
|
'--telemetry.banner=false',
|
2019-04-23 01:10:08 +02:00
|
|
|
`--server.maxPayloadBytes=1679958`,
|
2018-05-21 15:31:30 +02:00
|
|
|
],
|
|
|
|
},
|
2018-05-10 01:23:49 +02:00
|
|
|
|
2019-02-28 21:06:00 +01:00
|
|
|
services
|
2017-05-18 03:53:45 +02:00
|
|
|
};
|
|
|
|
}
|