Skip to content
This repository has been archived by the owner on Feb 22, 2022. It is now read-only.

[stable/concourse] Segregate Prometheus service from Web service #10881

Closed
cirocosta opened this issue Jan 24, 2019 · 4 comments
Closed

[stable/concourse] Segregate Prometheus service from Web service #10881

cirocosta opened this issue Jan 24, 2019 · 4 comments
Labels
lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale.

Comments

@cirocosta
Copy link
Collaborator

Hey,

With the addition of the Prometheus port to web-svc in #6338, an operator exposing the web service publicly using the service type LoadBalancer ends up exposing their metrics out there.

For instance:

web:
  service:
    type: LoadBalancer
    loadBalancerIP: 1.2.3.4
concourse:
  web:
    prometheus:
      enabled: true

produces:

# Source: concourse/templates/web-svc.yaml
apiVersion: v1
kind: Service
metadata:
  name: release-name-web
  labels:
    app: release-name-web
    chart: "concourse-3.6.2"
    release: "release-name"
    heritage: "Tiller"
  annotations:
    prometheus.io/scrape: "true"
    prometheus.io/port: "9391"
spec:
  type: LoadBalancer
  loadBalancerIP: 1.2.3.4
  ports:
    - name: atc
      port: 8080
      targetPort: atc
    - name: tsa
      port: 2222
      targetPort: tsa
    - name: prometheus
      port: 9391
      targetPort: prometheus
  selector:
    app: release-name-web

It seems to me that to solve that while still supporting the use case described in the PR mentioned above, we could have a separate Prometheus service.

Maybe that is something that we could enable by default to be backward compatible, but leave that configurable under a separate field.

For instance:

web:
  service:
    type: LoadBalancer
    loadBalancerIP: 1.2.3.4
concourse:
  web:
    prometheus:
      enabled: true

prometheus:
  service:
    enabled: true
    # some additional properties ...

With such configuration, the following scenarios could exist:

  • web service w/ Prometheus scraping the pods directly (from user-configured additional pod annotations);
  • web service w/ Prometheus scraping the separate service (private); and
  • web service w/ Prometheus scraping the separate service (public).

Wdyt?

Thanks!


cc @william-tran

@ghost ghost mentioned this issue Feb 8, 2019
3 tasks
@stale
Copy link

stale bot commented Feb 23, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Any further update will cause the issue/pull request to no longer be considered stale. Thank you for your contributions.

@stale stale bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Feb 23, 2019
@cirocosta
Copy link
Collaborator Author

#11289 (comment) 🙌

@stale stale bot removed the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Feb 23, 2019
@stale
Copy link

stale bot commented Mar 25, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Any further update will cause the issue/pull request to no longer be considered stale. Thank you for your contributions.

@stale stale bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Mar 25, 2019
@stale
Copy link

stale bot commented Apr 8, 2019

This issue is being automatically closed due to inactivity.

@stale stale bot closed this as completed Apr 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale.
Projects
None yet
Development

No branches or pull requests

1 participant