Hi again Brian,
That worked nicely for the password :)

Now i just need to figure out a way to something similar with username, as 
i know that my organization architects will be poiting fingers at me if i 
commit something to git with a username in it :)

Your help is as usual much appreciated :)

Best

Christian Oelsner

lørdag den 22. april 2023 kl. 21.00.04 UTC+2 skrev Christian Oelsner:

> Hello Brian,
> thank you for your input. I will give a try and see where that takes me :) 
>
> Best regards
> Christian Oelsner
>
> lørdag den 22. april 2023 kl. 00.43.16 UTC+2 skrev Brian Candler:
>
>> > But for the life of me, i cant seem to get prometheus to pick it up in 
>> the scrape job.
>> > Am i missing the obvious?
>>
>> Environment-variable substitution is not performed in prometheus' config 
>> file.
>>
>> You could expose the secret containing the password as a file, rather 
>> than an environment variable:
>>
>> https://kubernetes.io/docs/concepts/configuration/secret/#using-secrets-as-files-from-a-pod
>>
>> basic_auth:
>>   username: some_static_username
>>   password_file: /path/to/file
>>
>> The username, though, still has to be included inline.
>>
>> Since you're deploying via helm, there might be some way the helm chart 
>> lets you insert these values into the prometheus configuration.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/prometheus-users/14630fc5-b324-4ca2-bafd-59331b0d0db8n%40googlegroups.com.

Reply via email to