-
Notifications
You must be signed in to change notification settings - Fork 104
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Nginx has been configured to listen on a second port (controlled by `cc.prom_metrics_server_tls_port`) and use a special set of certs (controlled by `cc.prom_scraper_tls`) to communicate with the `prom_scraper`. `prom_scraper` requires that the certificate of the server that it's scraping is signed with the same CA cert that every other endpoint in the deployment that it is scraping is signed with. So -rather than massively complicate configuration for our existing server configuration- we have decided to create a second server with its own configuration. Co-authored-by: Kenneth Lakin <[email protected]> Co-authored-by: Michael Oleske <[email protected]> Co-authored-by: David Alvarado <[email protected]> Co-authored-by: Merric de Launey <[email protected]>
- Loading branch information
1 parent
a243a4e
commit c92ded0
Showing
7 changed files
with
117 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
jobs/cloud_controller_ng/templates/prom_scraper_config.yml.erb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
port: <%= p("cc.prom_metrics_server_tls_port") %> | ||
source_id: "cloud_controller_ng" | ||
instance_id: <%= spec.id || spec.index.to_s %> | ||
scheme: https | ||
server_name: <%= p("cc.internal_service_hostname") %> | ||
path: /internal/v4/metrics |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
ssl_ciphers DHE-RSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384; | ||
ssl_certificate /var/vcap/jobs/cloud_controller_ng/config/certs/scrape.crt; | ||
ssl_certificate_key /var/vcap/jobs/cloud_controller_ng/config/certs/scrape.key; | ||
ssl_client_certificate /var/vcap/jobs/cloud_controller_ng/config/certs/scrape_ca.crt; | ||
ssl_verify_client on; | ||
ssl_verify_depth 2; | ||
ssl_protocols TLSv1.2; | ||
ssl_session_cache shared:SSL:10m; | ||
ssl_session_timeout 10m; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<%= p('cc.prom_scraper_tls.public_cert') %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<%= p('cc.prom_scraper_tls.private_key') %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<%= p('cc.prom_scraper_tls.ca_cert') %> |