Skip to content

Automatically create network policies to allow Prometheus metrics scraping traffic for workloads annotated with prometheus.io/scrape#295

Merged
zohar7ch merged 3 commits intomainfrom
zohar7ch/new-chard-for-allowing-metrics-collection-traffic
Apr 1, 2025
Merged

Automatically create network policies to allow Prometheus metrics scraping traffic for workloads annotated with prometheus.io/scrape#295
zohar7ch merged 3 commits intomainfrom
zohar7ch/new-chard-for-allowing-metrics-collection-traffic

Conversation

@zohar7ch
Copy link
Copy Markdown
Contributor

@zohar7ch zohar7ch commented Mar 24, 2025

Description

By setting intentsOperator.operator.automateThirdPartyNetworkPolicies and intentsOperator.operator.prometheusServerConfigs - Otterize can now automatically enable traffic from Prometheus server to any other workload marked with prometheus.io/scrape annotation.

You no longer have to create client-intents from the scraping server to your workloads.

References

Checklist

  • I have added documentation for new/changed functionality in this PR and in github.com/otterize/docs

@zohar7ch zohar7ch force-pushed the zohar7ch/new-chard-for-allowing-metrics-collection-traffic branch from 50b1b5e to 93d2e6b Compare March 24, 2025 20:35
@zohar7ch zohar7ch changed the title Automatically enable metrics scraping for workloads that are marked with the Prometheus scraping annotation Automatically create network policies to allow Prometheus scraping traffic for workloads annotated with prometheus.io/scrape Mar 25, 2025
@zohar7ch zohar7ch force-pushed the zohar7ch/new-chard-for-allowing-metrics-collection-traffic branch from 8717cf7 to cfb915e Compare March 30, 2025 11:42
zohar7ch added 3 commits April 1, 2025 19:02
Since now we support auto-enable metrics collection traffic (for
Prometheus server), we introduce a new flag that sets whether the
product should automate all the third party network policies (for what
that used to be called external-traffic and new kine of Prometheus
metrics scraping traffic).
When enabling automateThirdPartyNetworkPolicies - it has an affect on
external traffic and metrics collection traffic.
In order to the metrics collection traffinc auto-enabling to work - you
have to pass MetricsScrapingServiceConfigs - so the operator would be
able to identify the Prometheus (\ other metrics scraping server) in the
network.
@zohar7ch zohar7ch force-pushed the zohar7ch/new-chard-for-allowing-metrics-collection-traffic branch from cfb915e to 2598797 Compare April 1, 2025 16:02
@zohar7ch zohar7ch changed the title Automatically create network policies to allow Prometheus scraping traffic for workloads annotated with prometheus.io/scrape Automatically create network policies to allow Prometheus metrics scraping traffic for workloads annotated with prometheus.io/scrape Apr 1, 2025
@zohar7ch zohar7ch merged commit cb19fca into main Apr 1, 2025
10 checks passed
@zohar7ch zohar7ch deleted the zohar7ch/new-chard-for-allowing-metrics-collection-traffic branch April 1, 2025 16:12
@github-actions github-actions bot locked and limited conversation to collaborators Apr 1, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants