Skip to content

Instantly share code, notes, and snippets.

View martwz's full-sized avatar
🤖
the singularity is nearer

Martin martwz

🤖
the singularity is nearer
View GitHub Profile
@martwz
martwz / example.com
Created November 18, 2018 22:50 — forked from 1hakr/example.com
Supercharge your NGIX config
proxy_cache_path /tmp/cacheapi levels=1:2 keys_zone=microcacheapi:100m max_size=1g inactive=1d use_temp_path=off;
server {
listen 443 ssl http2 default_server;
listen [::]:443 ssl http2 default_server;
server_name example.com;
location /api/ {
# Rate Limiting
limit_req zone=reqlimit burst=20; # Max burst of request
#!/bin/bash
VIDEOS=~/Desktop/Wedding/
find "$VIDEOS" -name '*.mp4' -exec sh -c 'avconv -i "$0" -c:v libvpx -crf 10 -b:v 1M -c:a libvorbis "${0%%.mp4}.webm"' {} \;
find "$VIDEOS" -name '*.mkv' -exec sh -c 'avconv -i "$0" -c:v libvpx -crf 10 -b:v 1M -c:a libvorbis "${0%%.mkv}.webm"' {} \;
find "$VIDEOS" -name '*.avi' -exec sh -c 'avconv -i "$0" -c:v libvpx -crf 10 -b:v 1M -c:a libvorbis "${0%%.avi}.webm"' {} \;
find "$VIDEOS" -name '*.AVI' -exec sh -c 'avconv -i "$0" -c:v libvpx -crf 10 -b:v 1M -c:a libvorbis "${0%%.AVI}.webm"' {} \;
find "$VIDEOS" -name '*.MPG' -exec sh -c 'avconv -i "$0" -c:v libvpx -crf 10 -b:v 1M -c:a libvorbis "${0%%.MPG}.webm"' {} \;
find "$VIDEOS" -name '*.wmv' -exec sh -c 'avconv -i "$0" -c:v libvpx -crf 10 -b:v 1M -c:a libvorbis "${0%%.wmv}.webm"' {} \;
find "$VIDEOS" -name '*.MOV' -exec sh -c 'avconv -i "$0" -c:v libvpx -crf 10 -b:v 1M -c:a libvorbis "${0%%.MOV}.webm"' {} \;
find "$VIDEOS" -name '*.mov' -exec sh -c 'avconv -i "$0" -c:v libvpx -crf 10 -b:v 1M -c:a libvorbis "${0%%.mov}