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

Redis authentication support? #6854

Closed
jathek opened this issue Aug 6, 2021 · 5 comments
Closed

Redis authentication support? #6854

jathek opened this issue Aug 6, 2021 · 5 comments

Comments

@jathek
Copy link

jathek commented Aug 6, 2021

📋 Description

Please support Redis password protected instances. I went through the documentation and it appears that Shields can only connect to unprotected Redis instances.

@calebcartwright
Copy link
Member

it appears that Shields can only connect to unprotected Redis instances.

That's incorrect.

Additionally, it's very rare that a self-hosted Shields server actually needs to utilize a Redis instance for a pool of GitHub tokens as opposed to just using a single token (https://github.com/badges/shields/blob/master/doc/server-secrets.md#github). The only time you'd actually need to use Redis with a self-hosted instance is if you have a single self-hosted Shields server that's hitting GitHub's rate limits (5k requests/hour to GitHub, or 15k/hour for GitHub Enterprise Cloud).

Are you hitting such rate limits using a single GitHub token? If not could you expand on why you need the Redis-backed pool of GitHub tokens?

Regarding the Redis piece itself, for Shields.io we use, and strongly encourage any self-hosters to use, TLS connections (not enabled by default). We utilize Compose.io for Shields.io Redis hosting with TLS connections utilizing the ioredis package, and we include the auth information within the Redis URL (e.g. rediss://user:password@....). We just use this as the means for specifying Redis authentication credentials as opposed to having an additional set of configuration variables.

https://www.compose.com/articles/ssl-connections-arrive-for-redis-on-compose/

@jathek
Copy link
Author

jathek commented Aug 6, 2021

Are you hitting such rate limits using a single GitHub token? If not could you expand on why you need the Redis-backed pool of GitHub tokens?

No I'm not, I just had a redis server so I thought I might as well connect it.

Regarding the Redis piece itself, for Shields.io we use, and strongly encourage any self-hosters to use, TLS connections (not enabled by default). We utilize Compose.io for Shields.io Redis hosting with TLS connections utilizing the ioredis package, and we include the auth information within the Redis URL (e.g. rediss://user:password@....). We just use this as the means for specifying Redis authentication credentials as opposed to having an additional set of configuration variables.

I'm sorry I missed this if it was documented somewhere, thanks.

@calebcartwright
Copy link
Member

I'm sorry I missed this if it was documented somewhere, thanks.

No worries! I actually don't think it's called out specifically anywhere, though including auth in the url/connection string with Redis is pretty common and well known. It might be helpful to expand the documentation a bit.

No I'm not, I just had a redis server so I thought I might as well connect it.

Gotcha. Definitely not needed, and definitely won't do anything for your server so would advise skipping it.

@jathek
Copy link
Author

jathek commented Aug 6, 2021

I did get it working with my redis container after your comment, just out of curiosity, but I'll take it out since I'll never need it.

Nothing else to do here, so I'll close. Thanks!

@jathek jathek closed this as completed Aug 6, 2021
@paulmelnikow
Copy link
Member

@nearcatch If you have a few minutes to try to improve the self-hosting documentation to clarify this point about not needing Redis for the next person, contributions would be welcome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants