mirror of
https://github.com/azures04/crafatar.git
synced 2026-05-06 11:00:39 +02:00
@@ -17,5 +17,5 @@ if (cluster.isMaster) {
|
||||
|
||||
setInterval(cleaner.run, config.cleaning_interval * 1000);
|
||||
} else {
|
||||
require("../server.js")();
|
||||
require("../server.js").boot();
|
||||
}
|
||||
@@ -111,7 +111,7 @@ h4 {
|
||||
}
|
||||
|
||||
.code .example {
|
||||
cursor: pointer;
|
||||
cursor: text;
|
||||
}
|
||||
|
||||
.code .example:hover {
|
||||
|
||||
@@ -94,7 +94,9 @@ exp.boot = function(callback) {
|
||||
var bind_ip = process.env.BIND || "127.0.0.1";
|
||||
logging.log("Server running on http://" + bind_ip + ":" + port + "/");
|
||||
server = http.createServer(requestHandler).listen(port, bind_ip, function() {
|
||||
if (callback) {
|
||||
callback();
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
@@ -102,12 +104,12 @@ exp.close = function(callback) {
|
||||
server.close(function() {
|
||||
callback();
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
module.exports = exp;
|
||||
|
||||
if (require.main === module) {
|
||||
exp.boot(function(){});
|
||||
exp.boot();
|
||||
|
||||
// cleaning worker
|
||||
setInterval(clean.run, config.cleaning_interval * 1000);
|
||||
|
||||
Reference in New Issue
Block a user