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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker compatibility 馃馃檹 #429

Closed
wants to merge 1 commit into from
Closed

Docker compatibility 馃馃檹 #429

wants to merge 1 commit into from

Conversation

glushchenko
Copy link

No description provided.

Docker compatibility 馃馃檹
@simonmichael
Copy link
Owner

Thanks. If I understand rightly, this makes hledger-web also respond to incoming requests to any IP address configured for this machine, rather than just local requests from this machine ? Any comments on #432 which goes the other way ?

Is it cross-platform ? http://serverfault.com/a/300410 says "ping 0.0.0.0 on a Windows system results in an error message".

@simonmichael simonmichael added A-WISH Some kind of improvement request, hare-brained proposal, or plea. web The hledger-web tool. labels Nov 20, 2016
@simonmichael
Copy link
Owner

For hledger-web and hledger-api, I am thinking it's best to be consistent, to listen only on localhost by default, and to add a --host option which would allow 0.0.0.0 or other address to be configured.

@simonmichael
Copy link
Owner

OR (devil's advocate): we can prioritise just-works over secure-by-default, keep things simple, and assume that people starting a web service should expect that it will serve web requests.

@glushchenko
Copy link
Author

--host argument is a good idea

@mhansen
Copy link
Contributor

mhansen commented Nov 20, 2016

+1 to a --host option (secure-by-default) now that there's a use case for the option :-)

simonmichael added a commit that referenced this pull request Nov 21, 2016
This came up in the context of Docker, but it seems it wasn't possible
for hledger-web to serve remote clients directly (without a proxy)
because of 127.0.0.1 being hardcoded ? Now that can be
changed with --host=IPADDR. The default base url also
uses this address, rather than "localhost" being hardcoded.

Also, the --server flag sounded too close in meaning to --host so
I've renamed it to --serve. The old spelling is still accepted,
at least through the next major release I suppose.
@simonmichael
Copy link
Owner

hledger-web --host IPADDR should work now. (I feel it should accept hostnames too, +1 to anyone who fixes that.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-WISH Some kind of improvement request, hare-brained proposal, or plea. web The hledger-web tool.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants