-
Notifications
You must be signed in to change notification settings - Fork 28
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
Add domains on the fly #47
Comments
Adding domains on the fly isn't supported yet, but could probably be added. Could you describe your usecase a little more? If I understood your use case correctly you would like to add (and presumably remove) additional domains, which may not share the same TLD, on the fly. Not sure I understood the parts about wildcard dns and the subdomain, so I'm not sure if that is relevant here. I think there is one key consideration. Do you want one or a few certs for all domains (iirc Let's Encrypt allows about a hundred), or many certs for many sets of domains. Different rate limits may apply to each case. I suspect the latter is more robust and scalable, so I'll focus on that in the following. I can think of three ways to go about this:
(1) seems like a low-hanging fruit and generally useful. (3) is a nice composition of existing features (after (1) is implemented). Do you think (some/all of) these options would match your requirements? Also, this sound like you may be working on a commercial service. If that is the case, feel free to contact me at |
Thank you for the description, i'm not too familiar with rustls and how certificates work but i indeed envisioned the latter where i store lots of certs in the database and choose one as needed (with a local cache of course). |
To prevent misunderstandings: You can't do this at the moment with rustls-acme (well, you might, but it's not obvious how). I'm trying to understand your use case better to come up with a solution that makes sense. The 3 options above were ideas for implementations. I'm a bit confused what exactly you want to accomplish, so here are a few questions/notes:
If you don't want to deal with certificate and rustls details, the high-level API is probably what you want. Please have a look at it and let me know if that sufficient for you if a way to add/remove domains is added. |
I know it's not yet possible, but i was thinking of forking it to make it work, sounds like it should be feasible. |
It's ugly, but should work. Only if you inject before starting the state management though. I'm considering implementing a pinning compatible mechanism where you can specify a cert instead of a new one being generated. That would have the side effect of covering this usecase.
I don't see any overlap between how this crate works and the dashmap idea. I think there may still be some fundamental misconceptions about how this crate is used. I would recommend that you start using the crate with a fixed set of domains to figure out how the existing interface could be extended to add more domains in a convenient way.
Currently it does when a certifcate is missing (so currently at startup), but not for renewals.
Not quite. You would have to touch multiple places. Most importantly the underlying state machine has to be generalized to mutliple sets of certificates if you want to be able to scale beyond 100 domains. I suspect that this will become possible quite soon by using the lower level API and simply running multiple instances of |
nice :) |
I started reworking the crate pretty fundamentally based around a new |
with the latest push it is almost ready, it just needs the caching and the acceptors. |
Hi,
I am implemententing an auto-whitelabel fature on my service based on the host. For this i use wildcard dns resolution, and allow clients to register custom domains on the same service that will change based on host, at least one subdomain is provided.
Is this crate capable of adding new domains on the fly ?
The text was updated successfully, but these errors were encountered: