Skip to content

Instantly share code, notes, and snippets.

View abshkd's full-sized avatar
:shipit:
Focusing

Abhishek Dujari abshkd

:shipit:
Focusing
View GitHub Profile
@abshkd
abshkd / worker nginx conf
Created November 6, 2015 11:33 — forked from fqrouter/worker nginx conf
Youtube Reverse Proxy
resolver 8.8.8.8;
location /video/ {
if ($request_uri ~ "^/video/(.+?)/.+") {
set $upstream_host $1.googlevideo.com;
add_header Content-Disposition "attachment; filename=video.mp4;";
}
rewrite /video/.+?/(.+)$ /$1 break;
proxy_buffering off;
proxy_pass https://$upstream_host;
proxy_set_header Host $upstream_host;
@abshkd
abshkd / glacier.py
Created August 22, 2012 10:05 — forked from ewindisch/glacier.py
glacier python client with multipart
#!/usr/bin/env python
#
# Copyright (c) 2012 Eric Windisch <eric@cloudscaling.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions: