supabase / supabase-grafana

Observability for your Supabase project, using Prometheus/Grafana
https://supabase.com
MIT License
189 stars 37 forks source link

I can't setup multi project #13

Closed gabrielsestrem closed 8 months ago

gabrielsestrem commented 9 months ago

Describe the bug

I can't use multiproject with this repository

To Reproduce

In the file entrypoint.sh line 5 there's this code:

if [ -z "$SUPABASE_ACCESS_TOKEN" ]; then

this will lead to single project monitoring, if I have SUPABASE_ACESS_TOKEN. I had to populate SUPABASE_ACCESS_TOKEN to monitor multiple projects. So it does not goes into the 'else' in line 22.

encima commented 8 months ago

Thanks for this, we will update the README to make this clearer. For multi project monitoring, you only need to set the project ref and service role key.

In bash, the -z check is checking for an empty string so it will go to the else when it is unset or set to nothing.