Skip to content

Instantly share code, notes, and snippets.

sudo rpm -ivh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
sudo yum install docker-io
sudo service docker start
sudo chkconfig docker on
http://www.tecmint.com/install-and-enable-rpmforge-repository-in-rhel-centos-6-5-4/
// This function returns an ObjectId embedded with a given datetime
// Accepts both Date object and string input
function objectIdWithTimestamp(timestamp){
// Convert string date to Date object (otherwise assume timestamp is a date)
if (typeof(timestamp) == 'string') {
timestamp = new Date(timestamp);
}
// Convert date object to hex seconds since Unix epoch
var flowFilterLog = require('pomelo-logger').getLogger('flowFilter', __filename);
module.exports = function () {
return new Filter();
};
var Filter = function () {
this.requestQueue = []
this.runApiList = []
};
http://www.programmerinn.com/
https://fengche.co/
http://www.apcow.com/
http://www.apcow.com/
http://shixian.com/
http://www.histarter.com/
http://www.freebon.cn/
db.areas.aggregate(
[
{
$project: {
areaId: 1,
numberOfResource: { $size: "$resources" }
}
}
]
)
http://superuser.com/questions/127863/manually-closing-a-port-from-commandline
#include <vector>
#include <assert.h>
#include <stdio.h>
#include <stdint.h>
#include <stdlib.h>
typedef int32_t Score;
typedef int32_t UserId;
typedef int32_t Rank;
const Score kInvalidScore = -1;
// --- Compiling ---
$ wget http://download.redis.io/releases/redis-2.8.3.tar.gz
$ tar xzvf redis-2.8.3.tar.gz
$ cd redis-2.8.3
$ make
$ make install
// --- or using yum ---
$ rpm -Uvh http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
$ rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
@jiangzhuo
jiangzhuo / gist:953f3054c8814ffbc0ea
Created April 10, 2015 09:19
create vpn server on CentOS6 with one command
wget http://www.hi-vps.com/shell/vpn_centos6.sh
sh vpn_centos6.sh