Project Description
Simple Asset Server with combo files, auto update link version and io cache.

START:

node cluster.js


config.json:

{
	"keepInMem"	:true,		//io cache
	"listen"	:"14445",	//listen port
	"filePath"	:"/home/liuwenbo/domob/assets3.0",	//asset file root
	"tmpPath"	:"/home/liuwenbo/tmp/combo",		//file cache path
"comboPathName"	:"/combo/",		//perfix before frist '?' in request url
	"compile"	:false,		//compile js
	"compiler"	: "YUI",	//compiler
	"log"		:true,		//log access
	"logFile"	:"/home/liuwenbo/logs/asseter_access.log", //log file
	"MIME" : {
		"jpg":	"image/jpeg",
		"gif":	"image/gif",
		"png":	"image/png",
		"ico":	"image/x-icon",
		"icon":	"image/x-icon",
		"css":	"text/css",
		"js":	"text/javascript",
		"html":	"text/html",
		"htm":	"text/html",
		"txt":	"text/plain"
	},
	"clinetCacheExt" : {	//allow clinet cache
		"jpg":	true,
		"gif":	true,
		"png":	true,
		"ico":	true,
		"icon":	true,
		"css":	true,
		"js":	true,
		"html":	true,
		"htm":	true,
		"txt":	true
	},
	"clinetZipExt" : {	//allow server zip file to reduce transfer size
		"css":	true,
		"js":	true,
		"html":	true,
		"htm":	true,
		"txt":	true
	}
}

Last edited Jan 6, 2013 at 7:47 AM by Xiao4, version 5