Skip to content

Instantly share code, notes, and snippets.

View henrysher's full-sized avatar
💭
I may be slow to respond.

Henry Huang henrysher

💭
I may be slow to respond.
View GitHub Profile
Code Transfer
Improvement
1. Staging info (大清理), Production (read) – Henry, wiki (to be updated) shared with us
2. ZMonitor and PMonitor(splunk) detail logging (and presented in the ops-portal) – Junyu, Jim
3. API rate exceed(staging, an/beta) – Henry, AWS support
4. launch tool的返回值改进 and fixed time sleep – Jim, tune
5. roles.json add regional - Henry
6. AMI tool update with latest packer (into docker) – Henry, Jim
7. S3 Configuration – perl to python, Henry
8. patch tool (local verify) -- Junyu
<local>,0.0.0.0/0,*.dev,*bj*.*,*51*.*,*91*.*,*ali*.*,*.cn*.*,*.cn,*china*.*,*0-6.com,*000dn.com,*000wan.com,*007.mx,*007ok.cc,*00base.com,*010lm.com,*010time.com,*016788.com,*01happy.com,*01hr.com,*01lm.com,*01shangwu.com,*020883.com,*021025.com,*022net.com,*022show.com,*023dg.com,*025tata.com,*02753.com,*027art.com,*028search.com,*028share.com,*029gc.net,*0371gt.com,*0394dk.com,*03964.com,*03wx.com,*05120512.com,*0512118114.com,*0512kd.com,*0531.com,*0532gc.com,*0532gcw.com,*0551bike.com,*0566che.com,*0569.com,*0574shop.com,*0577bike.com,*0577men.com,*0577net.com,*0577wh.com,*057s.com,*0592sl.com,*0595.com,*0598yu.com,*05jk.com,*05sun.com,*05wan.com,*060s.com,*061100.com,*0622jj.com,*06621.com,*0669.cc,*06climate.com,*07073.com,*0713hb.com,*071711.com,*0737mp.com,*075501.com,*0817cg.com,*08279.com,*0830bbs.com,*0931007.com,*09dy.com,*0x110.com,*1000chi.com,*1000eb.com,*10010.com,*10010js.com,*10086.com,*100che.org,*100ksw.com,*100ksw.net,*100tm.com,*100ydy.com,*100ye.com,*100yue.com,*10628106.com,*107cine.co
tutorials = [('Mining Social Web APIs with IPython Notebook', 'Novice'),
('A hands-on introduction to Python for beginning programmers', 'Novice'),
('How to formulate a (science) problem and analyze it using Python code', 'Novice'),
('0 to 00111100 with web2py', 'Novice'),
('Getting Started with Django, a crash course', 'Novice'),
('Django for Web Designers and Front End Developers ', 'Novice'),
('Python 3/2 Web Development with Pyramid', 'Novice'),
('Introduction to game programming', 'Novice'),
('Hands-on Beginning Python', 'Novice'),
('TDD for web applications, from scratch', 'Novice'),
{
'puppet_install_distributor': {
'display_name': 'Puppet Install Distributor',
'id': 'puppet_install_distributor',
'types': ['puppet_module']
},
'iso_distributor': {
'display_name': 'ISO Distributor',
'id': 'iso_distributor',
'types': ['iso']
@henrysher
henrysher / 0_reuse_code.js
Created July 23, 2014 04:23
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@henrysher
henrysher / gdb.output
Created August 28, 2014 05:32
gdb python2.7 hanging
(gdb) bt
#0 0x00007f6bae720bed in ?? () from /usr/local/lib/libpython2.7.so.1.0
#1 0x00007f6bae7215c2 in PyDict_GetItem () from /usr/local/lib/libpython2.7.so.1.0
#2 0x00007f6bae730c76 in PyString_InternInPlace () from /usr/local/lib/libpython2.7.so.1.0
#3 0x00007f6bae7a4002 in ?? () from /usr/local/lib/libpython2.7.so.1.0
#4 0x00007f6bae7a3615 in ?? () from /usr/local/lib/libpython2.7.so.1.0
#5 0x00007f6bae7a37a4 in ?? () from /usr/local/lib/libpython2.7.so.1.0
#6 0x00007f6bae7a3615 in ?? () from /usr/local/lib/libpython2.7.so.1.0
#7 0x00007f6bae7a377c in ?? () from /usr/local/lib/libpython2.7.so.1.0
#8 0x00007f6bae7a3615 in ?? () from /usr/local/lib/libpython2.7.so.1.0
@henrysher
henrysher / lsof.output
Created August 28, 2014 05:32
lsof python2.7 hanging
python2.7 22018 root cwd DIR 202,65 4096 131409 /root
python2.7 22018 root rtd DIR 202,65 4096 2 /
python2.7 22018 root txt REG 202,65 4864 533667 /usr/local/bin/python2.7
python2.7 22018 root mem REG 202,65 26144 659598 /usr/local/lib/python2.7/lib-dynload/strop.so
python2.7 22018 root mem REG 202,65 22240 659556 /usr/local/lib/python2.7/lib-dynload/_heapq.so
python2.7 22018 root mem REG 202,65 9904 659539 /usr/local/lib/python2.7/lib-dynload/_bisect.so
python2.7 22018 root mem REG 202,65 60872 659585 /usr/local/lib/python2.7/lib-dynload/itertools.so
python2.7 22018 root mem REG 202,65 41968 659590 /usr/local/lib/python2.7/lib-dynload/operator.so
python2.7 22018 root mem REG 202,65 33576 659547 /usr/local/lib/python2.7/lib-dy
@henrysher
henrysher / CVE-2015-0235.c
Created January 28, 2015 09:22
CVE-2015-0235
#include <netdb.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#define CANARY "in_the_coal_mine"
struct {
char buffer[1024];
@henrysher
henrysher / TwentyBot
Last active August 29, 2015 14:21 — forked from CodyWalker/TwentyBot
function countPieces() {
it = b.pieces();
var i = 0;
while (it.current()){ i++; it.next() }
return i;
}
function getRandPiece() {
var it = b.pieces();
var n = Math.floor(Math.random()*countPieces());
{
"name": "myweb",
"containers" : [{
"image": "httpd",
"ports": [{
"containerPort": 80,
"hostPort": 8080
}]
}],
"resource": {