-
Notifications
You must be signed in to change notification settings - Fork 0
Setup
- 2 GHz CPU is recommended. Though there is no actual limit, file/page processing may be annoyingly slow if your CPU is slow.
- 1-1.5 GB of free RAM. Technically, 200-300 MB should be enough, but due to a strange Node.js or Express bug memory consumption sometimes increases up to 700-800 MB for some 0.5-1 seconds and then decreases back to normal value.
- Any system where Node.js is supported (Windows, Linux, Mac OS, etc.) will be OK (in theory). Tested on Ubuntu 10.04 x32.
- Node.js 5.0.0+. 4.2.x may be OK, but this is not tested.
- file (should support video/webm MIME-type). File for Windows
Listed in package.json. Just npm install
them. Type the following in your terminal/console:
npm install deep-equal dot express express-device formidable jsdom merge mkpath q-io readline-sync request uuid
- When a form is parsed with
formidable
, multiple files with the same field name are parsed, but only one of them is finally available. So the saved file may not be deleted and pollutes temporary directory.
To fix this, apply the patch: cd patch && ./apply.sh
. You are using Windows? Deal with it.
Create config.json
. You may also create another configuration files (config.json
is git-ignored) and specify them as command line parameters:
./app.js ./config-dev.json
See config.json.example
for configuration example.
{
"serverPport": 8080, /*The port to listen to.*/
"site": {
"protocol": "http", /*Default site protocol.
If your site enorces SSL/TLS, change it to https.*/
"domain": "localhost:8080", /*Your site domain name.
You must change this for remote access.*/
"pathPrefix": "", /*Should be specified if there are several sites
running on the same host.*/
"dateFormat": "MM/DD/YYYY HH:mm:ss", /*Most of the dates on the site
will be formatted using this.*/
"timeOffset": 0 /*Server GMT time offset.*/
},
"maxProxyFail": 1, /*Maximum proxy fail count after which the proxy
will not be used anymore
(though it will be left in the list).*/
"captcha": {
"google-recaptcha-v1": {
"key": "Your 2captcha.com key" /*2captcha.com user access key*/
}
}
}
Create proxies.json
. See proxies.json.example
for configuration example.
[
{
"host": "127.0.0.1",
"port": 8080, /*Optional*/
"login": "login", /*Optional*/
"password": "password" /*Optional*/
}
]
Note: You HAVE to create proxies.json
. If you do not want to use proxies, just insert an empty list:
[]
You MUST create a public/js/data.js
file with valid content. See public/js/data.js.example
for an example. Currently site.pathPrefix
must be specified only. If you are running wipe.js as a separate site, just specify an empty string. If there are several sites running (for example, wipe.js is under the site.com/yourprefix/
prefix), you must specify that prefix (yourprefix/
according to the example).
Just put some images (or other files) into the files
subdirectory.
Create a ramdisk:
mkdir /mnt/tmpfs
chmod 777 /mnt/tmpfs
mount -t tmpfs -o size=xxxM tmpfs /mnt/tmpfs
Here xxx
is the ramdisk size in megabytes.
Now specify the path in config.json
:
...
"tmpPath": "/mnt/tmpfs"
100-200 MB of memory should be enough.