README - frontends - front-ends for some sites (experiment)
LogFilesRefsREADMELICENSE---
README (1488B)
---
1 Dependencies:
2 -------------
3
4 - C compiler.
5 - LibreSSL + libtls.
6
7
8 Compile
9 -------
10
11 - make
12 - doas make install
13
14
15 Features
16 --------
17
18 - Search videos.
19 - Doesn't use JavaScript.
20 - Doesn't use (tracking) cookies.
21 - CSS is optional.
22 - Multiple interfaces available: CGI web, CLI, gopher (gph), this is a
23 work-in-progress.
24 - Shows an Atom feed of the user/channel.
25 - Doesn't use or require the Google API.
26 - CGI interface works nice in most browsers, including text-based ones.
27 On OpenBSD it runs "sandboxed" and it can be compiled as a static-linked
28 binary with pledge(2), unveil(2) in a chroot.
29
30
31 Cons/caveats
32 ------------
33
34 - Order by upload date is incorrect (same as on Youtube).
35 - Some Youtube features are not supported.
36 - Uses scraping so might break at any point.
37
38
39 Install HTTP CGI
40 ----------------
41
42 Nginx + slowcgi example:
43
44 location /idiotbox/css/.* {
45 root /home/www/domains/www.codemadness.org/htdocs/idiotbox/css;
46 }
47
48 location ~ ^/idiotbox(/|/\?.*)$ {
49 include /etc/nginx/fastcgi_params;
50 fastcgi_pass unix:/run/slowcgi.sock;
51 fastcgi_param SCRIPT_FILENAME /cgi-bin/idiotbox;
52 fastcgi_param SCRIPT_NAME /cgi-bin/idiotbox;
53 fastcgi_param REQUEST_URI /cgi-bin/idiotbox;
54 }
55
56 httpd + slowcgi example:
57
58 location "/idiotbox" {
59 root "/cgi-bin/idiotbox.cgi"
60 fastcgi
61 }
62
63
64 When using a chroot make sure to copy /etc/resolv.conf and /etc/ssl/cert.pem.
65
66 To test from the command-line you can do:
67
68 QUERY_STRING="q=funny+cat+video" ./main | sed 1,2d | lynx -stdin