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

binding only to localhost #20

Open
Anniepoo opened this issue Nov 1, 2016 · 0 comments
Open

binding only to localhost #20

Anniepoo opened this issue Nov 1, 2016 · 0 comments

Comments

@Anniepoo
Copy link
Owner

Anniepoo commented Nov 1, 2016

from swish
handy way to bind only to localhost

%% server is det.
%% server(?Port) is det.
%
% Start the web-server on Port. Port may be unbound to make the
% system select a free port. Port can also be of the form
% localhost:Port to bind the server only to the localhost
% interface.

server :-
server(localhost:3050).
server(Port) :-
http_server(http_dispatch,
[ port(Port),
workers(16)
]).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant