Skip to content

Instantly share code, notes, and snippets.

View liruqi's full-sized avatar

Ruqi liruqi

View GitHub Profile

平台:DigitalOcean VPS ubuntu14.04 x64, strongswan5.2.2 运行以下命令请使用root权限

一:安装strongswan

由于ubuntu软件仓库中strongswan版本较低,因此从官网源码编译安装

apt-get install build-essential     #编译环境
aptitude install libgmp10 libgmp3-dev libssl-dev pkg-config libpcsclite-dev libpam0g-dev     #编译所需要的软件
正标题:SPECTACULAR FUTURE
副标题:ECO-CITY WITH PASSIVE HOUSE
作者简介:(配我的照片)
Qian Zhang, 20, Beijing
Qian is currently pursuing a bachelor’s degree in HAVC (Heating, Ventilating and Air Conditioning) at Beijing University of Civil Engineering and Architecture.
She had named “Beijing outstanding student cadre”.
Her studies focus on energy saving building.
Research Interests: Energy Saving Building, Room Environment, Interior Ventilation.
@liruqi
liruqi / iptables.conf
Last active June 25, 2017 15:12
iptables conf for 80 port HTTP proxy
#Drop ad click
IPSET=`which ipset`
match_set=""
if [ -x "$IPSET" ]; then
if $IPSET --version; then
if [ ! -f CHINA ]; then
wget "https://raw.github.com/liruqi/west-chamber-season-3/master/CHINA"
fi
@liruqi
liruqi / yii2-droplist
Last active August 29, 2015 14:17
Yii2 Drop list down value mapping
<?php
# Drop down list value mapping
# File models/Report.php
public function areaTypeMapping() {
return ['公共区域', '办公区域'];
}
# views/report/_form.php
@liruqi
liruqi / config
Created March 25, 2015 03:53
My software config
Terminal:
Menlo Regular 13 pt.
@liruqi
liruqi / CHINADDOS.ip
Last active August 29, 2015 14:11
China shadowsocks ddos
-N CHINADDOS nethash --hashsize 5000 --probes 2
-A CHINADDOS 1.180.132.2/32
-A CHINADDOS 1.180.68.122/32
-A CHINADDOS 1.180.80.122/32
-A CHINADDOS 1.183.104.90/32
-A CHINADDOS 1.189.209.20/32
-A CHINADDOS 1.191.188.147/32
-A CHINADDOS 1.192.24.215/32
-A CHINADDOS 1.194.223.228/32
-A CHINADDOS 1.198.113.153/32
@liruqi
liruqi / ipset-gen.py
Last active February 6, 2016 08:34
shadowsocks server config
# copied from: http://code.google.com/p/chnroutes/source/browse/trunk/chnroutes.py
import re
import urllib2
import sys
import argparse
import math
import json
def fetch_ip_data():
@liruqi
liruqi / cl.liruqi.info.conf
Created November 24, 2014 06:36
cl.liruqi.info config
server {
server_name cl.liruqi.info;
error_log /var/log/nginx/cl.liruqi.info.error.log;
access_log /var/log/nginx/cl.liruqi.info.access.log;
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_pass http://t66y.com/;
# sub_filter t66y.com cl.liruqi.info;
@liruqi
liruqi / nginxhttpproxy.conf
Created November 22, 2014 15:29
nginx http proxy config
server {
listen 80;
server_name *.cn *.org *.com *.jp *.hk *.io *.info "";
client_body_timeout 60000;
client_max_body_size 1024m;
send_timeout 60000;
client_header_buffer_size 16k;
large_client_header_buffers 4 64k;
@liruqi
liruqi / 2014-11-15
Created November 14, 2014 01:49
本周六(11月15日)交流题目
Leetcode:
1. Search for a Range
https://oj.leetcode.com/problems/search-for-a-range/
2. Median of Two Sorted Arrays
https://oj.leetcode.com/problems/median-of-two-sorted-arrays/
3. Longest Valid Parentheses
https://oj.leetcode.com/problems/longest-valid-parentheses/
4. Copy List with Random Pointer
https://oj.leetcode.com/problems/copy-list-with-random-pointer/