Installation instructions in the readme

This commit is contained in:
(≧◡≦) 2022-11-23 19:45:34 +01:00
parent e361669b87
commit 6d5632ee81
No known key found for this signature in database
GPG key ID: B39C0BCEE94A4A89

View file

@ -6,16 +6,46 @@
* Written in perl * Written in perl
* Can be used as pastebin * Can be used as pastebin
* Or as a URL shorter * Easy installation (just a simple daemon and use a reverse proxy)
* Easiy installation (just use fcgi)
* Runs with CGI
## Installation: 1. install the dependencies using `cpan`:
1. Configure your webserver to run CGI ~~~
2. If running nginx, set `client_max_body_size` to the max size of cpan -i Mojolicious::Lite Mojolicious::Routes::Pattern Mojoliciuos::Plugin::RenderFile
the file ~~~
2. There you go.
2. Clone the repo and start the daemon:
~~~
git clone https://git.suragu.net/dudemanweed/sakisafe
cd sakisafe/http
./sakisafe.pl daemon -m production
~~~
3. Create a 'f' directory in the directory sakisafe will run with
`mkdir f`. Make sure that the user which will run sakisafe.pl can
write in that directory.
By default, sakisafe will bind in 127.0.0.1 port 3000. Because that's
the default bind Mojolicious uses.
4. Create a proxy rule in nginx configuration (If you're using another
HTTP server, you're on your own.)
~~~conf
server {
server_name sakisafe.whatever.tld;
listen 443 ssl;
# ssl configuration here...
location / {
proxy_pass http://127.0.0.1:3000$request_uri;
}
}
~~~
And restart nginx. Going to `sakisafe.whatever.tld` should work.
# sakisafecli # sakisafecli