krz/skunky-art
Alternative privacy frontend for DeviantArt.
clone: git clone https://gitbay.org/krz/skunky-art.git
v1.3.7: SETUP.md · raw
1# Units
2Maximum file size in megabytes, requires numeric value.<br>
3Time units:
4* `i` — minutes
5* `h` — hours
6* `w` — weeks
7* `m` — months
8* `y` — years
9
10# Config
11* `listen` — IP and port to listen on in the following form: ip:port
12* `uri` — Instance URI. Example: `"uri":"/art/"` -> https://skunky.ebloid.ru/art/
13* `cache` — Caching system; default is off.
14 * `enabled` — Caching system state, requires boolean value
15 * `path` — Path to cache directory. It must be writable by the user SkunkyArt
16 runs as, and SkunkyArt refuses to start if it is not. The container image
17 runs as uid 10000, so a bind-mounted cache needs
18 `sudo chown -R 10000:10000 <dir>` on the host.
19 * `memcache` — Also keep served media in RAM, on top of the on-disk cache.
20 Entries are scored by how often they are requested and dropped once they go
21 a round unused. The cache is bounded only by that scoring, so leave it off
22 unless you have RAM to spare for your traffic.
23 * `lifetime` — Cached file life time, requires numeric value, followed by multiplicative suffix (see Time Units for details)
24 * `max-size` — Maximum file size in megabytes
25 * `update-interval` — Automatic rotation interval
26* `static-path` — This setting determines path to static, which will be copied to RAM when SkunkyArt is started. Useless if you're use binary compiled with 'embed' tag.
27* `download-proxy` — Outbound proxy used when fetching media from DeviantArt's
28 CDN. Leave empty (`""`) unless you actually run a proxy: if this points at
29 something that isn't listening, every image 502s while pages still render,
30 because only media fetches go through it. Inside a container `127.0.0.1` is
31 the container itself, so a host-side proxy must be addressed by service name
32 or host IP, not loopback.
33* `user-agent` — String, which SkunkyArt uses as UA
34* `proxy` — Serve media through this instance instead of linking straight to
35 DeviantArt's CDN. Required by `cache`; when off, clients fetch images from
36 wixmp directly.
37* `nsfw` — Show mature content.
38
39# Setting up reverse proxy
40Pretty much business as usual, except for the [`X-Forwarded-Proto`](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/X-Forwarded-Proto) header setting.
41
42Nginx example configuration:
43```apache
44server {
45 listen 443 ssl;
46 server_name skunky.example.com;
47
48 # In case of subdomain, use / instend of ((BASE_URL))
49 location ((BASE_URL)) {
50 proxy_set_header X-Forwarded-Proto $scheme;
51 proxy_set_header Host $host;
52 proxy_http_version 1.1;
53 proxy_pass http://((IP)):((PORT));
54 }
55}
56```