-
Notifications
You must be signed in to change notification settings - Fork 74
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
132 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
FROM dockerfile/elasticsearch | ||
MAINTAINER ChangHoon Jeong <iamseapy@gmail.com> | ||
|
||
ENV ES_HEAP_SIZE 1g | ||
|
||
ADD logging.yml /data/conf/logging.yml | ||
ADD elasticsearch.yml /data/conf/elasticsearch.yml | ||
|
||
RUN ["/elasticsearch/bin/plugin", "--install", "-Des.config=/data/conf/elasticsearch.yml", "royrusso/elasticsearch-HQ"] | ||
RUN ["/elasticsearch/bin/plugin", "--install", "-Des.config=/data/conf/elasticsearch.yml", "lukas-vlcek/bigdesk"] | ||
RUN ["/elasticsearch/bin/plugin", "--install", "-Des.config=/data/conf/elasticsearch.yml", "lmenezes/elasticsearch-kopf"] | ||
RUN ["/elasticsearch/bin/plugin", "--install", "-Des.config=/data/conf/elasticsearch.yml", "mobz/elasticsearch-head"] | ||
RUN ["/elasticsearch/bin/plugin", "--install", "-Des.config=/data/conf/elasticsearch.yml", "karmi/elasticsearch-paramedic"] | ||
|
||
ENTRYPOINT ["/elasticsearch/bin/elasticsearch", "--path.conf=/data/conf"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
# What's differ `dockerfile/elasticsearch` | ||
|
||
* pre install useful plugin | ||
* HQ | ||
* bigdesk | ||
* kopf | ||
* head | ||
* paramedic | ||
|
||
|
||
# Usage | ||
|
||
```shell | ||
# x.x.x.x server | ||
$ docker run -d -p 9200:9200 -p 9300:9300 \ | ||
-v /data/elasticsearch:/data/mnt \ | ||
seapy/elasticsearch \ | ||
--node.name=$(hostname) \ | ||
--network.publish_host=$(hostname -i) \ | ||
--discovery.zen.ping.multicast.enabled=false \ | ||
--discovery.zen.ping.unicast.hosts=x.x.x.x:9300,y.y.y.y:9300 | ||
``` | ||
|
||
```shell | ||
# y.y.y.y server | ||
$ docker run -d -p 9200:9200 -p 9300:9300 \ | ||
-v /data/elasticsearch:/data/mnt \ | ||
seapy/elasticsearch \ | ||
--node.name=$(hostname) \ | ||
--network.publish_host=$(hostname -i) \ | ||
--discovery.zen.ping.multicast.enabled=false \ | ||
--discovery.zen.ping.unicast.hosts=x.x.x.x:9300,y.y.y.y:9300 | ||
``` | ||
|
||
|
||
# Override conf | ||
|
||
you can overrinde config option like `cluster.name: my_cluster` | ||
|
||
```shell | ||
docker run -d ... seapy/elasticsearch --cluster.name: my_cluster | ||
``` | ||
|
||
|
||
# Info | ||
|
||
`--network.publish_host` options is key point. when you missed this, unicast cluster can't work. | ||
|
||
[Running an ElasticSearch Cluster on CoreOS](http://mattupstate.com/coreos/devops/2014/06/26/running-an-elasticsearch-cluster-on-coreos.html) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
cluster.name: elastic_docker | ||
|
||
# path | ||
path.conf: /data/conf | ||
path.data: /data/mnt/data | ||
path.logs: /data/mnt/log | ||
path.plugins: /elasticsearch/plugins | ||
path.work: /data/mnt/work | ||
|
||
# index option | ||
index.number_of_shards: 5 | ||
index.number_of_replicas: 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# you can override this using by setting a system property, for example -Des.logger.level=DEBUG | ||
es.logger.level: INFO | ||
rootLogger: ${es.logger.level}, console, file | ||
logger: | ||
# log action execution errors for easier debugging | ||
action: DEBUG | ||
# reduce the logging for aws, too much is logged under the default INFO | ||
com.amazonaws: WARN | ||
|
||
# gateway | ||
#gateway: DEBUG | ||
#index.gateway: DEBUG | ||
|
||
# peer shard recovery | ||
#indices.recovery: DEBUG | ||
|
||
# discovery | ||
#discovery: TRACE | ||
|
||
index.search.slowlog: TRACE, index_search_slow_log_file | ||
index.indexing.slowlog: TRACE, index_indexing_slow_log_file | ||
|
||
additivity: | ||
index.search.slowlog: false | ||
index.indexing.slowlog: false | ||
|
||
appender: | ||
console: | ||
type: console | ||
layout: | ||
type: consolePattern | ||
conversionPattern: "[%d{ISO8601}][%-5p][%-25c] %m%n" | ||
|
||
file: | ||
type: dailyRollingFile | ||
file: ${path.logs}/${cluster.name}.log | ||
datePattern: "'.'yyyy-MM-dd" | ||
layout: | ||
type: pattern | ||
conversionPattern: "[%d{ISO8601}][%-5p][%-25c] %m%n" | ||
|
||
index_search_slow_log_file: | ||
type: dailyRollingFile | ||
file: ${path.logs}/${cluster.name}_index_search_slowlog.log | ||
datePattern: "'.'yyyy-MM-dd" | ||
layout: | ||
type: pattern | ||
conversionPattern: "[%d{ISO8601}][%-5p][%-25c] %m%n" | ||
|
||
index_indexing_slow_log_file: | ||
type: dailyRollingFile | ||
file: ${path.logs}/${cluster.name}_index_indexing_slowlog.log | ||
datePattern: "'.'yyyy-MM-dd" | ||
layout: | ||
type: pattern | ||
conversionPattern: "[%d{ISO8601}][%-5p][%-25c] %m%n" |