diff options
| author | Pitu <[email protected]> | 2017-01-13 04:48:18 -0300 |
|---|---|---|
| committer | Pitu <[email protected]> | 2017-01-13 04:48:18 -0300 |
| commit | de975f0f62ff4e566f1660c528e8b8de8e69ac7c (patch) | |
| tree | 12f86471877a7cdd4a229abb70aa1fb20ff2076b | |
| parent | First version (diff) | |
| download | host.fuwn.me-de975f0f62ff4e566f1660c528e8b8de8e69ac7c.tar.xz host.fuwn.me-de975f0f62ff4e566f1660c528e8b8de8e69ac7c.zip | |
Updated readme
| -rw-r--r-- | README.md | 19 | ||||
| -rw-r--r-- | config.sample.js | 43 |
2 files changed, 57 insertions, 5 deletions
@@ -1,7 +1,16 @@ -<<<<<<< HEAD # loli-bank Pomf-like image uploading service, written in NodeJS -======= -# loli-safe -Pomf-like file uploading service, written in NodeJS ->>>>>>> b285f244150d0eb79376716501a97b9416497344 + +--- +1. Clone +2. Rename `config.sample.js` to `config.js` +3. Modify port and prvacy options if desired +4. run `npm install` to install all dependencies +5. run `node lolisafe.js` to start the service + +--- +## Using it +After the service is started, you can POST files to /api/upload . The file key needs to be called `file` and it should be a `multipart/form-data` upload, or else it will be disregarded. + +This works great with sharex, just like [mixtape.moe](https://mixtape.moe) and [cuntflaps.me](https://cuntflaps.me). +A chrome extension to be able to right click images -> send to safe is in the works.
\ No newline at end of file diff --git a/config.sample.js b/config.sample.js new file mode 100644 index 0000000..ce9cb70 --- /dev/null +++ b/config.sample.js @@ -0,0 +1,43 @@ +module.exports = { + + // Port on which to run the server + port: 9999, + + // Upload restrictions + privacy: { + + // Is the service public? If so, anyone with the URL can upload files + public: false, + + // If not, which IP's should be able to access? + IPs: [ + '::1', + '127.0.0.1' + ] + }, + + // Uploads config + uploads: { + + // Folder where images should be stored + folder: 'uploads', + + // Max file size allowed + maxsize: '512MB' + }, + + // Folder where to store logs + logsFolder: 'logs', + + // The length of the random generated name for the uploaded files + fileLength: 4, + + // The following values shouldn't be touched + database: { + client: 'sqlite3', + connection: { + filename: './db' + }, + useNullAsDefault: true + } +}
\ No newline at end of file |