Skip to content

config/index.js hard-codes localhost as config.dev.host #1128

Closed
@b-jazz

Description

@b-jazz

If you override the host from localhost to 192.168.0.2 in your webpack config when starting webpack-dev-server, the script will still output "Your application is running here: http://localhost:8080" instead of "Your application is running here: http://192.168.0.2:8080".

I've fixed this locally by making the following config/index.js diff:

-    host: 'localhost', // can be overwritten by process.env.HOST
+    host: process.env.HOST || 'localhost', // can be overwritten by process.env.HOST

I'd issue a pull request but I'm not sure yet if this has any negative affect on things like tests.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions