-
Notifications
You must be signed in to change notification settings - Fork 154
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
[0.6.x] Support loading certificates from environment variables #151
[0.6.x] Support loading certificates from environment variables #151
Conversation
This pull request is ready for review. If you have a better name for |
Thanks for contributing to the core plugin @innocenzi ❤️ you rock. |
@innocenzi I'm wondering if we should first use the What do you think? The official plugin uses the |
Admittedly I never used I would say, we should probably wait for people with such setups to provide feedback if what the plugin offers doesn't work for them |
This PR adds support for loading certificates thanks to paths defined in the environment.
Currently, in our team, we use
valetTls
, which is very nice for us Valet users. But a member of our team uses Windows and Laragon, and cannot benefit from the configuration.With this PR, they will be able to define
VITE_DEV_SERVER_KEY
andVITE_DEV_SERVER_CERT
in their.env
with the paths to their Laragon certificates. That way, there is no need to touchvite.config.ts
, so it can keep being environment-agnostic.Keeping this as a draft to test it on my own Windows machine later- also, not so sure about the variable names:VITE_*
environment variables are available in the front-end throughimport.meta.env
.