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

specify ServerURL in options{}? #163

Open
x3nb63 opened this issue Mar 11, 2024 · 2 comments
Open

specify ServerURL in options{}? #163

x3nb63 opened this issue Mar 11, 2024 · 2 comments
Labels
blocked enhancement New feature or request

Comments

@x3nb63
Copy link

x3nb63 commented Mar 11, 2024

Hello,

I am in a situation where I can not set K6_PROMETHEUS_RW_SERVER_URL environment variable (nor any other env var) cause I do not control the invocation of k6 run .... All I can do is submit the script.js and specify which extensions should be loaded, thats all. So xk6-output-prometheus-remote does get loaded but then sends metrics to the default of localhost:9090 which fails and I cant make that port open either.

Is there a way to specify the prometheus connectivity settings (ServerURL, user, password) directly in options{}?

@x3nb63
Copy link
Author

x3nb63 commented Mar 11, 2024

Playing some more I find that I also need K6_PROMETHEUS_RW_STALE_MARKERS=true, K6_PROMETHEUS_RW_PUSH_INTERVAL=60 and K6_PROMETHEUS_RW_TREND_STATS='p(95),max' to get meaningful metrics for graphing my case.

Being able to set all these environment options from the script options{} would be really great.

@olegbespalov
Copy link
Contributor

Hi @x3nb63 !

Unfortunately, it's not possible right now to configure extensions via options 😢

We know this is an issue, and to some degree, the grafana/k6#883 should address it.

I'm just keeping this issue open for future prioritization/reference.

@olegbespalov olegbespalov added enhancement New feature or request blocked and removed triage labels Mar 14, 2024
@olegbespalov olegbespalov removed their assignment Mar 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants