{# plugins/prometheus/templates/prometheus/form.html — add or edit a scrape target (milestone 506): where its /metrics is, its token, how often, and what to keep, with Test to scrape it once before saving. The token is never sent back to the browser; a blank token field keeps the stored one. #} {% extends "base.html" %} {% from "_macros.html" import crumbs, page_header %} {% block title %}{{ ("Edit " ~ target.name) if target else "Add Prometheus target" }} — Steward{% endblock %} {% from "prometheus/_tabs.html" import prometheus_tabs %} {% block section_tabs %}{{ prometheus_tabs("targets") }}{% endblock %} {% block breadcrumb %} {%- if target -%} {{ crumbs([("Prometheus", "/plugins/prometheus/"), (target.name, "/plugins/prometheus/targets/" ~ target.id), ("Edit", "")]) }} {%- else -%} {{ crumbs([("Prometheus", "/plugins/prometheus/"), ("Add target", "")]) }} {%- endif -%} {% endblock %} {% block content %} {{ page_header(("Edit " ~ target.name) if target else "Add Prometheus target") }}
{{ error }}
{% endif %} {% if target %}Steward stops scraping it. Its past series age out with the rest of the history.