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

Look in to pulling DEV_PORT and DEV_HOST values from .env #1913

Open
jwoertink opened this issue Sep 19, 2024 · 0 comments
Open

Look in to pulling DEV_PORT and DEV_HOST values from .env #1913

jwoertink opened this issue Sep 19, 2024 · 0 comments
Labels
needs investigation A possible bug / better docs needed. Investigate further

Comments

@jwoertink
Copy link
Member

If you want to specify a custom port or custom host that's different from your config/watch.yml, you can set the DEV_PORT and DEV_HOST env vars; however, these have to be set at the CLI level.

DEV_PORT=3002 lucky dev

Alternatively, you can specify these in your Procfile.dev

web: DEV_PORT=3002 lucky watch

The reason these don't read from the .env is because the watch task will be precompiled in to your bin/ dir, and your .env file isn't read until after this task is created.

The downside to not reading from the .env is that you may want to run on a different port than the rest of your team, so you don't want to add changes that will get added in to git, and you may forget to add it before calling lucky dev and maybe you don't want to make an alias shortcut for yourself.

I've briefly looked in to this issue, and it seems like a rather big refactor, but if someone else wants to look in to this without having to change how Lucky runs or making any breaking changes to the code, I'd be open to a PR.

@jwoertink jwoertink added the needs investigation A possible bug / better docs needed. Investigate further label Sep 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs investigation A possible bug / better docs needed. Investigate further
Projects
None yet
Development

No branches or pull requests

1 participant