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

CORS: Leave user configure CORS in prometheus.yml #5010

Closed
aloababa opened this Issue Dec 18, 2018 · 3 comments

Comments

Projects
None yet
4 participants
@aloababa
Copy link

aloababa commented Dec 18, 2018

According to prometheus code Allowed Origin is always set to '*'.

var corsHeaders = map[string]string{ "Access-Control-Allow-Headers": "Accept, Authorization, Content-Type, Origin", "Access-Control-Allow-Methods": "GET, OPTIONS", "Access-Control-Allow-Origin": "*", "Access-Control-Expose-Headers": "Date", }

So what if i want a single allowed origin ?

It would be nice to allow user configure allowed origins or disable cors in prometheus.yml

@brian-brazil

This comment has been minimized.

Copy link
Member

brian-brazil commented Dec 18, 2018

Per previous discussions, this would make more sense as a flag.

@geekodour

This comment has been minimized.

Copy link
Contributor

geekodour commented Dec 18, 2018

I'll try to send a PR for this one today.

@cstyan

This comment has been minimized.

Copy link
Contributor

cstyan commented Jan 22, 2019

looks like the two PR's fix this, can we close?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.