aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
AgeCommit message (Collapse)Author
2018-11-21Add license (mostly GNU AGPLv3+)Teddy Wing
License the software with the GNU AGPLv3+ with the exception of the 'aquatic-prime' and 'paddle' libraries and 'aquatic-prime' binary, which are licensed under the GNU GPLv3+.
2018-11-20deployment: Use normal .htaccess instead of `production-config` oneTeddy Wing
When I removed the environment variables from the `.htaccess` file in 7d7ac8d747be198088664e45e5423919d9876651, it no longer needed a corresponding `production-config` counterpart. Use the one tracked in the repository instead.
2018-11-20Make an MPEG-4 version of the demo videoTeddy Wing
Apparently, Safari doesn't support h.264-encoded video with a frame size larger than 640x480. Learned about it from this Stack Overflow answer: https://stackoverflow.com/questions/20347352/html5-video-tag-not-working-in-safari-iphone-and-ipad/31247386#31247386 According to Apple's documentation: > The following compression standards are supported: > > * H.264 Baseline Profile Level 3.0 video, up to 640 x 480 at 30 fps. > Note that B frames are not supported in the Baseline profile. > * MPEG-4 Part 2 video (Simple Profile) > * AAC-LC audio, up to 48 kHz (https://developer.apple.com/library/archive/documentation/AppleApplications/Reference/SafariWebContent/CreatingVideoforSafarioniPhone/CreatingVideoforSafarioniPhone.html#//apple_ref/doc/uid/TP40006514-SW9) Seems a bit odd to me, but I don't know video, so sure, why not? Since I want to keep my atypical video dimensions, encode it in MPEG-4 following this guide: https://trac.ffmpeg.org/wiki/Encode/MPEG-4 Unfortunately, this gives us a 12 Mb video file (compared to the h.264's ~3 Mb). Reducing the quality just didn't produce a decent-looking output. Deciding to keep the h.264 version, just in case it's supported somewhere, because it's the version with the smallest file size.
2018-11-20post-deploy.sh: Restart FastCGI processesTeddy Wing
2018-11-20Add deployment scriptTeddy Wing
To deploy, run $ make deploy This checks prerequisites and runs `scripts/deploy.sh`. Makefile: Include a new target that builds the Rust binaries for Linux using Docker. The script `rsync`s the website files to the server, moves some files around on the server, and runs the database migrations. Currently I'm getting an error at the database migration stage, as it seems I can't use `UTC_TIMESTAMP()` as a default column value. Need to correct that to get a clean deployment.
2018-11-19Add video_export.shTeddy Wing
These are the commands I used to convert the demo video into HTML5-suitable video formats. The commands are copied from guides I found on the net looking for `ffmpeg` HTML5 video conversion. I did add the `-b 275k` setting on the WebM video to sort of match the bitrate I saw on the MP4 video. Otherwise it ends up being horrible quality without the flag, or around 14 Mb with the `-b:v 1M` flag (this version results in ~4 Mb).
2018-11-13internal_error.html: Fix logo imageTeddy Wing
Hadn't tested this when I made it. Was outputting a formatted byte string instead of the plain base64, which resulted in `b'BASE_64'` being inserted. Output the real base64 to get the image to decode properly.
2018-11-13Add 500 error page with generatorTeddy Wing
Base structure copied from `404.html`. Python script based on the `generate_homebrew_formula.py` script in the main DomeKey repository. The filename comes from the Apache server configuration. Generate the 500 page because we can't rely on dependencies. This gets the CSS and logo and includes them inline in the HTML page. Thanks to this answer for explaining how to get a byte string from a file to send to the base64 encoder: https://stackoverflow.com/questions/45482272/typeerror-a-bytes-like-object-is-required-not-str-python-2-to-3/45482834#45482834