Skip to content

Commit b1bfd4d

Browse files
committed
Added to README.md.
1 parent 8707ae2 commit b1bfd4d

File tree

1 file changed

+22
-4
lines changed

1 file changed

+22
-4
lines changed

README.md

Lines changed: 22 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ This is a simple Web application that, for any URL path, serves the
66
contents of an Etherpad with the same path with the MIME type
77
`text/html`.
88

9-
For example, if the application is served from `htmlpad.org` and the
9+
For example, if the application is served from htmlpad.org and the
1010
Etherpad backend it's configured to use is at
11-
`etherpad.mozilla.org:9000`, then visiting `http://htmlpad.org/foo`
12-
will deliver the contents of `http://etherpad.mozilla.org:9000/foo` as
11+
etherpad.mozilla.org:9000, then visiting http://htmlpad.org/foo
12+
will deliver the contents of http://etherpad.mozilla.org:9000/foo as
1313
HTML.
1414

1515
This effectively allows people to easily collaborate on writing HTML,
@@ -18,11 +18,29 @@ out, seeing how it looks in the browser, and sharing it with others.
1818

1919
### Installation ###
2020

21-
Just run `python manage.py runserver` and open your browser to [http://localhost:8000](http://localhost:8000).
21+
Just run `python manage.py runserver` and open your browser to [http://localhost:8000](http://localhost:8000). As you save changes to HTMLpad's source code, the server will automatically apply them, allowing you to iterate quickly.
22+
23+
### Troubleshooting ###
24+
25+
While HTMLpad is a Django application, you don't need to have Django installed system-wide. That's because running `manage.py` automatically creates a virtual environment, downloads and installs the appropriate version of Django and any other dependencies, and activates the virtual environment for the duration of the script.
26+
27+
However, this can sometimes result in a broken virtual environment, particularly if `manage.py` is aborted while it's still setting things up. If anything goes amiss, try wiping the `.virtualenv` directory and try again.
2228

2329
### Deployment ###
2430

31+
You can run `python setup.py install` to install the `htmlpad` Django application package into any environment, including virtual ones.
32+
33+
This Django application assumes the following custom settings variables:
34+
35+
* `HTMLPAD_ROOT` is the string prefix, including any trailing slash but no leading slash, of the HTMLpad instance on the Web server. It can be an empty string. For example, if a user browses to http://foo.com/mypad/ to access your HTMLpad's root, then the setting's value is `'mypad/'`.
36+
37+
* `ETHERPAD_HOST` is the Etherpad instance that your HTMLpad delegates to, formatted as a hostname:port string.
38+
2539
See the [hackasaurus-puppet-data][] repository for Puppet deployment files.
2640

41+
### Security Considerations ###
42+
43+
Because the HTMLpad simply delivers universally-writeable Etherpad content as raw HTML, an HTMLpad instance should probably be served on its own dedicated domain.
44+
2745
[hackasaurus-puppet-data]: https://github.com/toolness/hackasaurus-puppet-data
2846
[Atul Varma]: http://toolness.com

0 commit comments

Comments
 (0)