Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
docker-elk
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
段孔乐
docker-elk
Commits
c0dcc248
Unverified
Commit
c0dcc248
authored
Jun 24, 2020
by
Antoine Cotten
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update to v7.8.0
parent
155c33cc
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
34 additions
and
13 deletions
+34
-13
.env
.env
+1
-1
.travis.yml
.travis.yml
+5
-1
elasticsearch-setup-passwords.exp
.travis/elasticsearch-setup-passwords.exp
+1
-1
testing.sh
.travis/lib/testing.sh
+2
-2
run-tests-core.sh
.travis/run-tests-core.sh
+1
-1
README.md
README.md
+5
-4
docker-stack.yml
docker-stack.yml
+3
-3
README.md
extensions/enterprise-search/README.md
+16
-0
No files found.
.env
View file @
c0dcc248
ELK_VERSION=7.
7.1
ELK_VERSION=7.
8.0
.travis.yml
View file @
c0dcc248
...
...
@@ -19,7 +19,7 @@ before_script:
-
docker-compose build
# Use built-in users with passwords set by 'elasticsearch-setup-passwords.exp'
-
sed -i -e 's/\(elasticsearch.username:\) elastic/\1 kibana/g' -e 's/\(elasticsearch.password:\) changeme/\1 testpasswd/g' kibana/config/kibana.yml
-
sed -i -e 's/\(elasticsearch.username:\) elastic/\1 kibana
_system
/g' -e 's/\(elasticsearch.password:\) changeme/\1 testpasswd/g' kibana/config/kibana.yml
-
sed -i -e 's/\(xpack.monitoring.elasticsearch.username:\) elastic/\1 logstash_system/g' -e 's/\(xpack.monitoring.elasticsearch.password:\) changeme/\1 testpasswd/g' logstash/config/logstash.yml
-
sed -i 's/\(password =>\) "changeme"/\1 "testpasswd"/g' logstash/pipeline/logstash.conf
-
sed -i -e 's/\(elasticsearch.password:\) changeme/\1 testpasswd/g' -e 's/\(secret_management.encryption_keys:\)/\1 [test-encrypt]/g' extensions/enterprise-search/config/enterprise-search.yml
...
...
@@ -40,12 +40,16 @@ script:
# Extensions
# Enterprise Search
-
"
sed
-i
'$
a
xpack.security.authc.api_key.enabled:
true'
elasticsearch/config/elasticsearch.yml"
-
docker-compose restart elasticsearch
-
docker-compose -f docker-compose.yml -f extensions/enterprise-search/enterprise-search-compose.yml up -d enterprise-search
-
sleep 30
-
.travis/run-tests-enterprise-search.sh
-
docker-compose -f docker-compose.yml -f extensions/enterprise-search/enterprise-search-compose.yml ps
-
docker-compose -f docker-compose.yml -f extensions/enterprise-search/enterprise-search-compose.yml logs enterprise-search
-
docker-compose -f docker-compose.yml -f extensions/enterprise-search/enterprise-search-compose.yml stop enterprise-search
-
"
sed
-i
'/xpack.security.authc.api_key.enabled:
true/d'
elasticsearch/config/elasticsearch.yml"
-
docker-compose restart elasticsearch
# APM Server
-
docker-compose -f docker-compose.yml -f extensions/apm-server/apm-server-compose.yml up -d apm-server
-
.travis/run-tests-apm-server.sh
...
...
.travis/elasticsearch-setup-passwords.exp
View file @
c0dcc248
#!/usr/bin/expect -f
# List of expected users with dummy password
set user "(elastic|apm_system|kibana|logstash_system|beats_system|remote_monitoring_user)"
set user "(elastic|apm_system|kibana
_system
|logstash_system|beats_system|remote_monitoring_user)"
set password "testpasswd"
# Find elasticsearch container id
...
...
.travis/lib/testing.sh
View file @
c0dcc248
...
...
@@ -24,8 +24,8 @@ function poll_ready {
local
cid
local
output
# retry for max 1
20s (24
*5s)
for
_
in
$(
seq
1
24
)
;
do
# retry for max 1
80s (36
*5s)
for
_
in
$(
seq
1
36
)
;
do
cid
=
"
$(
docker ps
-q
-f
label
=
"
$label
"
)
"
if
[
-z
"
${
cid
:-}
"
]
;
then
echo
"Container exited"
...
...
.travis/run-tests-core.sh
View file @
c0dcc248
...
...
@@ -16,7 +16,7 @@ log 'Waiting for readiness of Elasticsearch'
poll_ready elasticsearch
'http://localhost:9200/'
'elastic:testpasswd'
log
'Waiting for readiness of Kibana'
poll_ready kibana
'http://localhost:5601/api/status'
'kibana:testpasswd'
poll_ready kibana
'http://localhost:5601/api/status'
'kibana
_system
:testpasswd'
log
'Waiting for readiness of Logstash'
poll_ready logstash
'http://localhost:9600/_node/pipelines/main?pretty'
...
...
README.md
View file @
c0dcc248
# Elastic stack (ELK) on Docker
[

](https://gitter.im/deviantony/docker-elk?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
[

](https://github.com/deviantony/docker-elk/issues/508
)
[

](https://github.com/deviantony/docker-elk/issues/515
)
[

](https://travis-ci.org/deviantony/docker-elk)
Run the latest version of the
[
Elastic stack
][
elk-stack
]
with Docker and Docker Compose.
...
...
@@ -170,8 +170,9 @@ Remove the `ELASTIC_PASSWORD` environment variable from the `elasticsearch` serv
3.
Replace usernames and passwords in configuration files
Use the
`kibana`
user inside the Kibana configuration file (
`kibana/config/kibana.yml`
) and the
`logstash_system`
user
inside the Logstash configuration file (
`logstash/config/logstash.yml`
) in place of the existing
`elastic`
user.
Use the
`kibana_system`
user (
`kibana`
for releases <7.8.0) inside the Kibana configuration file
(
`kibana/config/kibana.yml`
) and the
`logstash_system`
user inside the Logstash configuration file
(
`logstash/config/logstash.yml`
) in place of the existing
`elastic`
user.
Replace the password for the
`elastic`
user inside the Logstash pipeline file (
`logstash/pipeline/logstash.conf`
).
...
...
@@ -237,7 +238,7 @@ Create an index pattern via the Kibana API:
```
console
$
curl
-XPOST
-D-
'http://localhost:5601/api/saved_objects/index-pattern'
\
-H
'Content-Type: application/json'
\
-H
'kbn-version: 7.
7.1
'
\
-H
'kbn-version: 7.
8.0
'
\
-u
elastic:<your generated elastic password>
\
-d
'{"attributes":{"title":"logstash-*","timeFieldName":"@timestamp"}}'
```
...
...
docker-stack.yml
View file @
c0dcc248
...
...
@@ -3,7 +3,7 @@ version: '3.3'
services
:
elasticsearch
:
image
:
docker.elastic.co/elasticsearch/elasticsearch:7.
7.1
image
:
docker.elastic.co/elasticsearch/elasticsearch:7.
8.0
ports
:
-
"
9200:9200"
-
"
9300:9300"
...
...
@@ -23,7 +23,7 @@ services:
replicas
:
1
logstash
:
image
:
docker.elastic.co/logstash/logstash:7.
7.1
image
:
docker.elastic.co/logstash/logstash:7.
8.0
ports
:
-
"
5000:5000"
-
"
9600:9600"
...
...
@@ -41,7 +41,7 @@ services:
replicas
:
1
kibana
:
image
:
docker.elastic.co/kibana/kibana:7.
7.1
image
:
docker.elastic.co/kibana/kibana:7.
8.0
ports
:
-
"
5601:5601"
configs
:
...
...
extensions/enterprise-search/README.md
View file @
c0dcc248
...
...
@@ -44,6 +44,19 @@ secret_management.encryption_keys: [my_first_encryption_key, my_second_encryptio
> key=<generated AES key>
> ```
### Enable Elasticsearch's API key service
Enterprise Search requires Elasticsearch's built-in
[
API key service
][
es-security
]
to be enabled in order to start.
Unless Elasticsearch is configured to enable TLS on the HTTP interface (disabled by default), this service is disabled
by default.
To enable it, modify the Elasticsearch configuration file in
[
`elasticsearch/config/elasticsearch.yml`
][
config-es
]
and
add the following setting:
```
yaml
xpack.security.authc.api_key.enabled
:
true
```
### Start the server
To include Enterprise Search in the stack, run Docker Compose from the root of the repository with an additional command
...
...
@@ -117,3 +130,6 @@ Docker container: [Running Enterprise Search Using Docker][enterprisesearch-dock
[
enterprisesearch-config
]:
https://www.elastic.co/guide/en/enterprise-search/current/configuration.html
[
enterprisesearch-docker
]:
https://www.elastic.co/guide/en/enterprise-search/current/docker.html
[
enterprisesearch-docs
]:
https://www.elastic.co/guide/en/enterprise-search/current/index.html
[
es-security
]:
https://www.elastic.co/guide/en/elasticsearch/reference/current/security-settings.html#api-key-service-settings
[
config-es
]:
../../elasticsearch/config/elasticsearch.yml
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment