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
<uwsgi> | |
<socket>127.0.0.1:9090</socket> | |
<master/> | |
<workers>1</workers> | |
<vhost/> | |
<callable>app</callable> | |
<max-requests>10000</max-requests> | |
<harakiri>30</harakiri> | |
<memory-report/> | |
<logdate/> |
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
# -*- coding:utf-8 -*- | |
import sys, database, feedparser | |
reload(sys) | |
sys.setdefaultencoding('utf-8') | |
db = database.Connection(host='127.0.0.1', database='wudongqiankun', user='root', password='password') | |
class Dict(): | |
def __init__(self, d): |
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
王 | |
江 | |
周 | |
胡 | |
刘 | |
李 | |
吴 | |
毛 | |
温 | |
习 |
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
function decode(loca) { | |
var result = [], url = ""; | |
var line, rows, extra; | |
loca = loca.trim(); | |
if(loca === "") { | |
return ""; | |
} | |
line = Number(loca[0]); | |
rows = Math.floor((loca.length - 1) / line); | |
extra = (loca.length - 1) % line; |
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 urllib2 | |
def xiami_decode(s): | |
s = s.strip() | |
if not s: | |
return False | |
result = [] | |
line = int(s[0]) | |
rows = len(s[1:]) / line | |
extra = len(s[1:]) % line |
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
user www www; | |
worker_processes 1; | |
error_log /home/wwwlogs/nginx_error.log crit; | |
pid /usr/local/nginx/logs/nginx.pid; | |
#Specifies the value for maximum file descriptors that can be opened by this process. | |
worker_rlimit_nofile 51200; |
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
#!/bin/bash | |
PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin:~/bin | |
export PATH | |
# Check if user is root | |
if [ $(id -u) != "0" ]; then | |
echo "Error: You must be root to run this script, please use root to install lnmp" | |
exit 1 | |
fi |
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
[table=60%][tr][td][url=http://k2.au92.com/][color=#0000ff][u]Web Proxy[/u][/color][/url] | |
[color=#008000]广告位[/color] [align=right][b]Google提供[/b][/align] | |
[/td][/tr][/table] |
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
# -*- coding:utf-8 -*- | |
import requests, os, re, sys, time | |
from time import sleep | |
from threading import Thread | |
reload(sys) | |
sys.setdefaultencoding('utf8') | |
UPDATE_INTERVAL = 0.01 |
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
#!/bin/bash | |
#Funciont: Backup website and mysql database | |
#Author: licess | |
#Website: http://lnmp.org | |
#IMPORTANT!!!Please Setting the following Values! | |
bak_dir=/home/backup | |
if [ -d $bak_dir ]; then | |
echo 'begin' |