Differences between revisions 1 and 13 (spanning 12 versions)
Revision 1 as of 2005-08-28 08:34:04
Size: 260
Editor: mpm
Comment:
Revision 13 as of 2008-03-27 12:48:06
Size: 1702
Editor: abuehl
Comment: +cat
Deletions are marked like this. Additions are marked like this.
Line 1: Line 1:
Mercurial has a built-in web server which can be used for browsing a repository with a web browser or Mercurial has a built-in light-weight web server which can be used for browsing a repository with a web browser or
Line 9: Line 9:

The built-in web server is missing some features found in other web servers, including access control, authentication, SSL, etc.
These are especially useful if you want to be able to securely push to a web-based repository. Thus, if you want to make a more
permanent server, you should probably use a [:CGI_Install:CGI-based server].

Following are detailed options for using hg's HTTP server:
{{{
$ hg help serve
hg serve [OPTION]...

export the repository via HTTP

    Start a local HTTP repository browser and pull server.

    By default, the server logs accesses to stdout and errors to
    stderr. Use the "-A" and "-E" options to log to files.

options:

 -A --accesslog name of access log file to write to
 -d --daemon run server in background
    --daemon-pipefds used internally by daemon mode
 -E --errorlog name of error log file to write to
 -p --port port to use (default: 8000)
 -a --address address to use
 -n --name name to show in web pages (default: working dir)
    --webdir-conf name of the webdir config file (serve more than one repo)
    --pid-file name of file to write process ID to
    --stdio for remote clients
 -t --templates web templates to use
    --style template style to use
 -6 --ipv6 use IPv6 in addition to IPv4
}}}
----
CategoryCommand CategoryWeb

Mercurial has a built-in light-weight web server which can be used for browsing a repository with a web browser or for allowing remote machines to pull from you. To use it, simply run:

$ hg serve

And then point your web browser at http://localhost:8000/.

The built-in web server is missing some features found in other web servers, including access control, authentication, SSL, etc. These are especially useful if you want to be able to securely push to a web-based repository. Thus, if you want to make a more permanent server, you should probably use a [:CGI_Install:CGI-based server].

Following are detailed options for using hg's HTTP server:

$ hg help serve
hg serve [OPTION]...

export the repository via HTTP

    Start a local HTTP repository browser and pull server.

    By default, the server logs accesses to stdout and errors to
    stderr.  Use the "-A" and "-E" options to log to files.

options:

 -A --accesslog       name of access log file to write to
 -d --daemon          run server in background
    --daemon-pipefds  used internally by daemon mode
 -E --errorlog        name of error log file to write to
 -p --port            port to use (default: 8000)
 -a --address         address to use
 -n --name            name to show in web pages (default: working dir)
    --webdir-conf     name of the webdir config file (serve more than one repo)
    --pid-file        name of file to write process ID to
    --stdio           for remote clients
 -t --templates       web templates to use
    --style           template style to use
 -6 --ipv6            use IPv6 in addition to IPv4


CategoryCommand CategoryWeb

hgserve (last edited 2012-10-25 19:49:02 by mpm)