This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import argparse | |
import redis | |
def connect_redis(conn_dict): | |
conn = redis.StrictRedis(host=conn_dict['host'], | |
port=conn_dict['port'], | |
db=conn_dict['db']) | |
return conn |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# import config. | |
# You can change the default config with `make cnf="config_special.env" build` | |
cnf ?= config.env | |
include $(cnf) | |
export $(shell sed 's/=.*//' $(cnf)) | |
# import deploy config | |
# You can change the default deploy config with `make cnf="deploy_special.env" release` | |
dpl ?= deploy.env | |
include $(dpl) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
error_reporting( E_ALL ); | |
ini_set( 'display_errors', 1); | |
if(!isset($_GET['action'])){ | |
die('Param is missing. Look at the <a href="https://gist.github.com/2995743">source</a>.'); | |
} | |
switch($_GET['action']) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import copy | |
import logging | |
import os | |
import boto3 | |
logging.basicConfig(level=os.environ.get('LOG_LEVEL', 'INFO')) | |
ec2 = boto3.client('ec2') | |
logger = logging.getLogger(__name__) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Desktop Entry] | |
Version=1.0 | |
Encoding=UTF-8 | |
Name=Popcorn Time | |
Name[en_US]=Popcorn Time | |
GenericName=BitTorrent Stream Player | |
GenericName[en_US]=BitTorrent Stream Player | |
Comment=Run the Popcorn Time application | |
Comment[en_US]=Run the Popcorn Time application | |
Type=Application |