Configuration
server:
http_listen_network: tcp
http_listen_address: ""
http_listen_port: 9080
http_listen_conn_limit: 0
grpc_listen_network: tcp
grpc_listen_address: ""
grpc_listen_port: 0
grpc_listen_conn_limit: 0
tls_cipher_suites: ""
tls_min_version: ""
http_tls_config:
cert_file: ""
key_file: ""
client_auth_type: ""
client_ca_file: ""
grpc_tls_config:
cert_file: ""
key_file: ""
client_auth_type: ""
client_ca_file: ""
register_instrumentation: true
graceful_shutdown_timeout: 30s
http_server_read_timeout: 30s
http_server_write_timeout: 30s
http_server_idle_timeout: 2m0s
grpc_server_max_recv_msg_size: 4194304
grpc_server_max_send_msg_size: 4194304
grpc_server_max_concurrent_streams: 100
grpc_server_max_connection_idle: 2562047h47m16.854775807s
grpc_server_max_connection_age: 2562047h47m16.854775807s
grpc_server_max_connection_age_grace: 2562047h47m16.854775807s
grpc_server_keepalive_time: 2h0m0s
grpc_server_keepalive_timeout: 20s
grpc_server_min_time_between_pings: 5m0s
grpc_server_ping_without_stream_allowed: false
log_format: logfmt
log_level: info
log_source_ips_enabled: false
log_source_ips_header: ""
log_source_ips_regex: ""
log_request_at_info_level_enabled: false
http_path_prefix: ""
external_url: ""
health_check_target: null
disable: false
profiling_enabled: false
enable_runtime_reload: false
client:
url: ""
batchwait: 1s
batchsize: 1048576
follow_redirects: false
enable_http2: false
backoff_config:
min_period: 500ms
max_period: 5m0s
max_retries: 10
timeout: 10s
tenant_id: ""
drop_rate_limited_batches: false
stream_lag_labels: ""
clients:
- url: http://logger-stage.infra.al:3100/loki/api/v1/push
batchwait: 1s
batchsize: 1048576
follow_redirects: false
enable_http2: false
backoff_config:
min_period: 500ms
max_period: 5m0s
max_retries: 10
external_labels: |
hostname: va-a-dev-2
timeout: 10s
tenant_id: ""
drop_rate_limited_batches: false
stream_lag_labels: ""
positions:
sync_period: 5s
filename: /mnt/data/positions.yaml
ignore_invalid_yaml: false
scrape_configs:
- job_name: system
pipeline_stages:
- limit:
burst: 2000
drop: true
rate: 1000
- drop:
drop_counter_reason: too_old
older_than: 2h
- regex:
expression: \/(?P<filename>[^\/]+)$
source: filename
- labels:
filename: null
relabel_configs:
- separator: ;
regex: (.*)
target_label: __tmp
replacement: va-a-dev-2
action: replace
- source_labels: [__tmp]
separator: ;
regex: s(.*)-.*
target_label: swarm
replacement: s${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ([a-z].*)-([0-9]+|backup)
target_label: swarm
replacement: ${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ([a-z].*-(prod|prod[a-z]+))-.*
target_label: swarm
replacement: ${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ca[1-9]+
target_label: swarm
replacement: ca
action: replace
static_configs:
- targets:
- localhost
labels:
__path__: /var/log/*log
job: varlogs
- job_name: docker-swarm
pipeline_stages:
- limit:
burst: 2000
drop: true
rate: 1000
- drop:
drop_counter_reason: too_old
older_than: 2h
relabel_configs:
- source_labels: [__meta_docker_network_scope]
separator: ;
regex: (swarm)
replacement: $1
action: keep
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name]
separator: ;
regex: (aodb-dxb-prod-overlord_jaeger)
replacement: $1
action: drop
- separator: ;
regex: (.*)
target_label: __tmp
replacement: va-a-dev-2
action: replace
- source_labels: [__tmp]
separator: ;
regex: s(.*)-.*
target_label: swarm
replacement: s${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ([a-z].*)-([0-9]+|backup)
target_label: swarm
replacement: ${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ([a-z].*-(prod|prod[a-z]+))-.*
target_label: swarm
replacement: ${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ca[1-9]+
target_label: swarm
replacement: ca
action: replace
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name]
separator: ;
regex: (.*)
target_label: swarm_service
replacement: $1
action: replace
- source_labels: [__address__]
separator: ;
regex: (.*)
target_label: job
replacement: docker-swarm
action: replace
- source_labels: [__meta_docker_container_label_com_docker_stack_namespace]
separator: ;
regex: (.*)
target_label: swarm_stack
replacement: $1
action: replace
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name]
separator: ;
regex: ^([a-z0-9]+)-([a-z]+)-([a-z]+).+
target_label: app
replacement: $1
action: replace
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name]
separator: ;
regex: ^([a-z0-9]+)-([a-z]+)-([a-z]+).+
target_label: client
replacement: $2
action: replace
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name]
separator: ;
regex: ^([a-z0-9]+)-([a-z]+)-([a-z]+).+
target_label: env
replacement: $3
action: replace
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name]
separator: ;
regex: (adr|gcam|rt|pf|hba)-([a-z]+)-([a-z]+)-app_([a-zA-Z-]+)
target_label: component
replacement: $4
action: replace
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name]
separator: ;
regex: va-([a-z]+)-([a-z]+)-([a-z]+)-(([a-z]+)_(.*).*)
target_label: component
replacement: $6
action: replace
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name]
separator: ;
regex: (lmr)-([a-z]+)-([a-z]+)-app_([a-zA-Z1-9]+)
target_label: component
replacement: $4
action: replace
- source_labels: [swarm]
separator: ;
regex: (ca|ca-dxb-prod)
target_label: env
replacement: prod
action: replace
- source_labels: [swarm]
separator: ;
regex: ca
target_label: client
replacement: al
action: replace
- source_labels: [swarm]
separator: ;
regex: ca-dxb-prod
target_label: client
replacement: dxb
action: replace
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name, swarm]
separator: ;
regex: ca-admin-prod_gorush;(.*)
target_label: component
replacement: ${1}-gorush
action: replace
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name]
separator: ;
regex: ca-staff-bus-(.+)_.+
target_label: client
replacement: ${1}
action: replace
- source_labels: [__meta_docker_container_label_com_docker_swarm_service_name]
separator: ;
regex: ca-staff-bus-(.+)_.+
target_label: component
replacement: staff-bus
action: replace
- source_labels: [client]
separator: ;
regex: admin
target_label: client
replacement: al
action: replace
- source_labels: [env]
separator: ;
regex: (overlord|bus)
target_label: env
replacement: prod
action: replace
- source_labels: [app]
separator: ;
regex: community
target_label: app
replacement: ca
action: replace
docker_sd_configs:
- follow_redirects: true
enable_http2: true
host: unix:///var/run/docker.sock
port: 80
filters: []
host_networking_host: localhost
refresh_interval: 5s
static_configs: []
- job_name: docker-local
pipeline_stages:
- limit:
burst: 2000
drop: true
rate: 1000
- drop:
drop_counter_reason: too_old
older_than: 2h
- match:
selector: '{container_name=~"(^nginx$)"}'
stages:
- regex:
expression: .*\[[^\]]+]\s(?P<host>.*)\s(?P<status>[0-9]{3})\s".*
- labels:
host: null
status: null
- metrics:
nginx_responses_total:
config:
action: inc
description: nginx responses total by status code
prefix: al_
source: status
type: Counter
relabel_configs:
- separator: ;
regex: (.*)
target_label: __tmp
replacement: va-a-dev-2
action: replace
- source_labels: [__tmp]
separator: ;
regex: s(.*)-.*
target_label: swarm
replacement: s${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ([a-z].*)-([0-9]+|backup)
target_label: swarm
replacement: ${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ([a-z].*-(prod|prod[a-z]+))-.*
target_label: swarm
replacement: ${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ca[1-9]+
target_label: swarm
replacement: ca
action: replace
- source_labels: [__meta_docker_network_scope, __meta_docker_container_name]
separator: ;
regex: (local;.*|swarm;\/nginx)
replacement: $1
action: keep
- source_labels: [__meta_docker_container_name]
separator: ;
regex: \/(.+)
target_label: container_name
replacement: $1
action: replace
- source_labels: [__address__]
separator: ;
regex: (.*)
target_label: job
replacement: docker-local
action: replace
docker_sd_configs:
- follow_redirects: true
enable_http2: true
host: unix:///var/run/docker.sock
port: 80
filters: []
host_networking_host: localhost
refresh_interval: 5s
static_configs: []
- job_name: laravel
pipeline_stages:
- limit:
burst: 2000
drop: true
rate: 1000
- drop:
drop_counter_reason: too_old
older_than: 2h
- regex:
expression: \/(?P<filename>[^\/]+)\/_data\/laravel\.log$
source: filename
- regex:
expression: (?P<app>adr|va|pf)-(?P<client>[a-z]+)-(?P<env>[a-z]+)-(app_logs|app-fbo_logs)-(?P<component>[a-zA-Z-]+)
source: filename
- labels:
app: null
client: null
component: null
env: null
filename: null
- match:
selector: '{job="laravel"} |~ "(?i).*error.*"'
stages:
- metrics:
laravel_errors:
config:
action: inc
match_all: true
description: Laravel error counter
max_idle_duration: 1h
prefix: al_
type: Counter
- match:
selector: '{job="laravel", swarm=~"(ca|ca-dxb-prod)"} |~ ".*Gorush info.*"'
stages:
- metrics:
gorush_info:
config:
action: inc
match_all: true
description: Gorush info counter
max_idle_duration: 168h
prefix: al_
type: Counter
- match:
selector: '{job="laravel", swarm=~"(ca|ca-dxb-prod)"} |~ ".*Gorush error.*"'
stages:
- metrics:
gorush_error:
config:
action: inc
match_all: true
description: Gorush info counter
max_idle_duration: 168h
prefix: al_
type: Counter
relabel_configs:
- separator: ;
regex: (.*)
target_label: __tmp
replacement: va-a-dev-2
action: replace
- source_labels: [__tmp]
separator: ;
regex: s(.*)-.*
target_label: swarm
replacement: s${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ([a-z].*)-([0-9]+|backup)
target_label: swarm
replacement: ${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ([a-z].*-(prod|prod[a-z]+))-.*
target_label: swarm
replacement: ${1}
action: replace
- source_labels: [__tmp]
separator: ;
regex: ca[1-9]+
target_label: swarm
replacement: ca
action: replace
static_configs:
- targets:
- localhost
labels:
__path__: /var/lib/docker/volumes/*/_data/laravel.log
job: laravel
target_config:
sync_period: 10s
stdin: false
limits_config:
readline_rate: 1000
readline_burst: 2000
readline_rate_enabled: true
readline_rate_drop: true
max_streams: 1000
max_line_size: 0
max_line_size_truncate: false
tracing:
enabled: true
wal:
enabled: false
dir: ""
cleanSegmentsOlderThan: 0s