Skip to content

Instantly share code, notes, and snippets.

@gccyugi
gccyugi / supervisord.conf
Created June 27, 2012 03:22
supervisord sample conf
; Sample supervisor config file.
[unix_http_server]
file=/tmp/supervisor.sock ; (the path to the socket file)
;chmod=0700 ; socket file mode (default 0700)
;chown=nobody:nogroup ; socket file uid:gid owner
;username=user ; (default is no username (open server))
;password=123 ; (default is no password (open server))
[inet_http_server] ; inet (TCP) server disabled by default
@gccyugi
gccyugi / nginx.conf
Created June 1, 2012 03:35
tornado-nginx
user www-data;
worker_processes 1;
error_log /var/log/nginx/error.log;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
use epoll;
}
@gccyugi
gccyugi / huami.py
Created May 31, 2012 03:38
huami-python
#!/usr/bin/env python
#coding=utf8
import sys
import hmac
STR1 = 'snow'
STR2 = 'kise'
STR3 = 'sunlovesnow1990090127xykab'
@gccyugi
gccyugi / smsbao.py
Created May 23, 2012 06:53
smsbao-python-api
# -*- coding: utf-8 -*-
#
# Author: yugi
# Email: [email protected]
# Update: 2012/5/23 14:07
import md5 as mmd5
def md5(e):
@gccyugi
gccyugi / upyun.rb
Created May 18, 2012 06:57
upyun-ruby-api
# -*- coding: utf-8 -*-
#
# :author yugi
# :email [email protected]
# :update 2012/5/18 14:56
module UpyunHttpMixin
def md5(s)
require 'digest/md5'
@gccyugi
gccyugi / upyun.py
Created May 11, 2012 06:59
upyun-python-api
# -*- coding: utf-8 -*-
#
# :author yugi
# :email [email protected]
# :update 2012/5/18 15:06
import md5 as mmd5
DEBUG = False