Add metrics

This commit is contained in:
Till Faelligen 2024-08-19 14:53:24 +02:00
parent e466404b4f
commit 50bb114032
No known key found for this signature in database
GPG key ID: ACCDC9606D472758
2 changed files with 6 additions and 2 deletions

View file

@ -20,6 +20,10 @@ worker_listeners:
- {{ resource }} - {{ resource }}
{%- endfor %} {%- endfor %}
{% endif %} {% endif %}
- type: metrics
port: {{ port + 1 }}
resources:
- metrics
worker_log_config: {{ worker_log_config_filepath }} worker_log_config: {{ worker_log_config_filepath }}

View file

@ -880,7 +880,7 @@ def generate_worker_files(
worker_config = insert_worker_name_for_worker_config(worker_config, worker_name) worker_config = insert_worker_name_for_worker_config(worker_config, worker_name)
worker_config.update( worker_config.update(
{"name": worker_name, "port": str(worker_port)} {"name": worker_name, "port": worker_port}
) )
# Update the shared config with any worker_type specific options. The first of a # Update the shared config with any worker_type specific options. The first of a
@ -920,7 +920,7 @@ def generate_worker_files(
for worker_type in worker_types_set: for worker_type in worker_types_set:
nginx_upstreams.setdefault(worker_type, set()).add(worker_port) nginx_upstreams.setdefault(worker_type, set()).add(worker_port)
worker_port += 1 worker_port += 2
# Build the nginx location config blocks # Build the nginx location config blocks
nginx_location_config = "" nginx_location_config = ""