You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+22-4Lines changed: 22 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -6,10 +6,10 @@ This is a simple Web application that, for any URL path, serves the
6
6
contents of an Etherpad with the same path with the MIME type
7
7
`text/html`.
8
8
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
10
10
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
13
13
HTML.
14
14
15
15
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.
18
18
19
19
### Installation ###
20
20
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.
22
28
23
29
### Deployment ###
24
30
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
+
25
39
See the [hackasaurus-puppet-data][] repository for Puppet deployment files.
26
40
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.
0 commit comments