Merge branch 'consul-healthchecks' of kazu634/itamae into master
This commit is contained in:
commit
d63adfb1de
|
@ -1,6 +1,12 @@
|
|||
{
|
||||
"service": {
|
||||
"name": "consul",
|
||||
"port": 8600
|
||||
"port": 8600,
|
||||
"check":{
|
||||
"tcp": "localhost:8600",
|
||||
"interval": "60s",
|
||||
"timeout": "1s",
|
||||
"success_before_passing": 3
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,8 +21,6 @@ remote_file '/etc/consul.d/service-consul.json' do
|
|||
owner 'root'
|
||||
group 'root'
|
||||
mode '644'
|
||||
|
||||
only_if '{ node["consul"]["manager"]}'
|
||||
end
|
||||
|
||||
execute 'Reload supervisor' do
|
||||
|
|
|
@ -1,6 +1,12 @@
|
|||
{
|
||||
"service": {
|
||||
"name": "grafana",
|
||||
"port": 3000
|
||||
"port": 3000,
|
||||
"check":{
|
||||
"tcp": "localhost:3000",
|
||||
"tls_skip_verify": false,
|
||||
"interval": "60s",
|
||||
"timeout": "1s"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,6 +0,0 @@
|
|||
{
|
||||
"service": {
|
||||
"name": "loki",
|
||||
"port": 3100
|
||||
}
|
||||
}
|
|
@ -8,10 +8,14 @@
|
|||
end
|
||||
|
||||
# Deploy `prometheus` files:
|
||||
remote_file '/etc/loki/loki-config.yml' do
|
||||
template '/etc/loki/loki-config.yml' do
|
||||
owner 'root'
|
||||
group 'root'
|
||||
mode '644'
|
||||
|
||||
variables(ipaddr: node['consul']['ipaddr'])
|
||||
|
||||
notifies :restart, 'service[loki]'
|
||||
end
|
||||
|
||||
# Deploy `systemd` configuration for `prometheus`:
|
||||
|
@ -27,11 +31,13 @@ service 'loki' do
|
|||
end
|
||||
|
||||
# Depoy `consul` service configuration for `loki`:
|
||||
remote_file '/etc/consul.d/service-loki.json' do
|
||||
template '/etc/consul.d/service-loki.json' do
|
||||
owner 'root'
|
||||
group 'root'
|
||||
mode '644'
|
||||
|
||||
variables(ipaddr: node['consul']['ipaddr'])
|
||||
|
||||
notifies :restart, 'service[supervisor]'
|
||||
end
|
||||
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
{
|
||||
"service": {
|
||||
"name": "loki",
|
||||
"port": 3100,
|
||||
"check":{
|
||||
"tcp": "<%= @ipaddr %>:3100",
|
||||
"interval": "60s",
|
||||
"timeout": "1s",
|
||||
"success_before_passing": 3
|
||||
}
|
||||
}
|
||||
}
|
|
@ -0,0 +1,45 @@
|
|||
auth_enabled: false
|
||||
|
||||
server:
|
||||
http_listen_port: 3100
|
||||
|
||||
ingester:
|
||||
lifecycler:
|
||||
address: 127.0.0.1
|
||||
ring:
|
||||
kvstore:
|
||||
store: inmemory
|
||||
replication_factor: 1
|
||||
final_sleep: 0s
|
||||
chunk_idle_period: 5m
|
||||
chunk_retain_period: 30s
|
||||
max_transfer_retries: 0
|
||||
|
||||
schema_config:
|
||||
configs:
|
||||
- from: 2018-04-15
|
||||
store: boltdb
|
||||
object_store: filesystem
|
||||
schema: v11
|
||||
index:
|
||||
prefix: index_
|
||||
period: 168h
|
||||
|
||||
storage_config:
|
||||
boltdb:
|
||||
directory: /var/opt/loki/index
|
||||
|
||||
filesystem:
|
||||
directory: /var/opt/loki/chunks
|
||||
|
||||
limits_config:
|
||||
enforce_metric_name: false
|
||||
reject_old_samples: true
|
||||
reject_old_samples_max_age: 168h
|
||||
|
||||
chunk_store_config:
|
||||
max_look_back_period: 0s
|
||||
|
||||
table_manager:
|
||||
retention_deletes_enabled: false
|
||||
retention_period: 0s
|
|
@ -1,6 +1,14 @@
|
|||
{
|
||||
"service": {
|
||||
"name": "filestat-exporter",
|
||||
"port": 60000
|
||||
"port": 60000,
|
||||
"check":{
|
||||
"http": "http://localhost:60000/filestat_exporter/metrics",
|
||||
"tls_skip_verify": false,
|
||||
"interval": "60s",
|
||||
"timeout": "1s",
|
||||
"status": "passing",
|
||||
"success_before_passing": 3
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,6 +1,13 @@
|
|||
{
|
||||
"service": {
|
||||
"name": "node-exporter",
|
||||
"port": 60000
|
||||
"port": 60000,
|
||||
"check":{
|
||||
"http": "http://localhost:60000/node_exporter/metrics",
|
||||
"tls_skip_verify": false,
|
||||
"interval": "60s",
|
||||
"timeout": "1s",
|
||||
"success_before_passing": 3
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,6 +1,13 @@
|
|||
{
|
||||
"service": {
|
||||
"name": "prometheus",
|
||||
"port": 9100
|
||||
"port": 9090,
|
||||
"check":{
|
||||
"http": "http://localhost:9090/",
|
||||
"tls_skip_verify": false,
|
||||
"interval": "60s",
|
||||
"timeout": "1s",
|
||||
"success_before_passing": 3
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue