Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exporter: Listen at port 9972 for Prometheus exporter. #3195

Merged

Conversation

chundonglinlin
Copy link
Member

Exporter add default port listen for Prometheus. SRS organization applies for the default port(9972) at the official Prometheus address(Default port allocations).You can see prometheus.conf,

listen              1935;
max_connections     1000;
daemon              off;
srs_log_tank        console;
http_api {
    enabled         on;
    listen          1985;
}
http_server {
    enabled         on;
    listen          8080;
}
rtc_server {
    enabled on;
    listen 8000; # UDP port
    # @see https://ossrs.net/lts/zh-cn/docs/v4/doc/webrtc#config-candidate
    candidate $CANDIDATE;
}
# Prometheus exporter config.
exporter {
    enabled         on;
    listen          9972;
    label           cn-beijing;
    tag             cn-edge;
}
vhost __defaultVhost__ {
    hls {
        enabled         on;
    }
    http_remux {
        enabled     on;
        mount       [vhost]/[app]/[stream].flv;
    }
    rtc {
        enabled     on;
        # @see https://ossrs.net/lts/zh-cn/docs/v4/doc/webrtc#rtmp-to-rtc
        rtmp_to_rtc on;
        # @see https://ossrs.net/lts/zh-cn/docs/v4/doc/webrtc#rtc-to-rtmp
        rtc_to_rtmp on;
    }
}

@chundonglinlin chundonglinlin force-pushed the feature/support-metrics-for-prometheus branch 3 times, most recently from 280942c to 6974ed9 Compare September 30, 2022 11:16
@chundonglinlin chundonglinlin force-pushed the feature/support-metrics-for-prometheus branch from 6974ed9 to 38c347a Compare September 30, 2022 12:26
@winlinvip winlinvip changed the title Exporter: listen default port and add prometheus config. Exporter: Listen at port 9972 for Prometheus exporter. Sep 30, 2022
@winlinvip winlinvip merged commit 9525511 into ossrs:develop Sep 30, 2022
johzzy pushed a commit to johzzy/srs that referenced this pull request Jun 26, 2023
@winlinvip winlinvip added the TransByAI Translated by AI/GPT. label Jul 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
TransByAI Translated by AI/GPT.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants