feat(elk): add Elasticsearch configuration template and bind mount for elasticsearch.yml
This commit is contained in:
parent
5ca5fac50b
commit
d7f8939bad
1 changed files with 42 additions and 0 deletions
|
@ -78,6 +78,12 @@ job "elk" {
|
|||
source = "local/unicast_hosts.txt"
|
||||
target = "/usr/share/elasticsearch/config/unicast_hosts.txt"
|
||||
}
|
||||
|
||||
mount {
|
||||
type = "bind"
|
||||
source = "local/elasticsearch.yml"
|
||||
target = "/usr/share/elasticsearch/config/elasticsearch.yml"
|
||||
}
|
||||
}
|
||||
|
||||
env {
|
||||
|
@ -89,6 +95,42 @@ job "elk" {
|
|||
memory = 2048
|
||||
}
|
||||
|
||||
template {
|
||||
data = <<-EOF
|
||||
cluster:
|
||||
name: "docker-cluster"
|
||||
node:
|
||||
name: {{ env "node.unique.name" }}
|
||||
network:
|
||||
host: 0.0.0.0
|
||||
publish_host: "{{ env "NOMAD_IP_transport" }}"
|
||||
discovery:
|
||||
seed_providers: file
|
||||
xpack:
|
||||
security:
|
||||
enrollment:
|
||||
enabled: true
|
||||
transport:
|
||||
ssl:
|
||||
enabled: true
|
||||
verification_mode: certificate
|
||||
client_authentication: required
|
||||
keystore:
|
||||
path: certs/elastic-certificates.p12
|
||||
truststore:
|
||||
path: certs/elastic-certificates.p12
|
||||
http:
|
||||
ssl:
|
||||
enabled: true
|
||||
keystore:
|
||||
path: certs/http.p12
|
||||
bootstrap:
|
||||
memory_lock: true
|
||||
EOF
|
||||
|
||||
destination = "local/elasticsearch.yml"
|
||||
}
|
||||
|
||||
template {
|
||||
data = <<-EOF
|
||||
{{ range service "elk-node-elasticsearch-transport" }}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue