mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-24 00:23:12 +09:00
6 files changed
+106
-9682
No files matched your search
@@ -0,0 +1,8 @@
|
|||||||
|
# Snyk (https://snyk.io) policy file, patches or ignores known vulnerabilities.
|
||||||
|
version: v1.12.0
|
||||||
|
ignore: {}
|
||||||
|
# patches apply the minimum changes required to fix a vulnerability
|
||||||
|
patch:
|
||||||
|
'npm:lodash:20180130':
|
||||||
|
- html5-validator > caporal > cli-table2 > lodash:
|
||||||
|
patched: '2018-07-03T06:07:55.532Z'
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
language: node_js
|
language: node_js
|
||||||
node_js:
|
node_js:
|
||||||
- "node"
|
- "9"
|
||||||
before_install:
|
before_install:
|
||||||
- sudo apt-get -qq update
|
- sudo apt-get -qq update
|
||||||
- sudo apt-get install -y curl git tar
|
- sudo apt-get install -y curl git tar
|
||||||
|
|||||||
+8
-6
@@ -1,15 +1,17 @@
|
|||||||
FROM node:latest
|
FROM node:9.11.2
|
||||||
RUN apt-get update && apt install git -y
|
RUN apt-get update && apt install git curl tar -y
|
||||||
|
|
||||||
RUN mkdir factorioClusterio
|
RUN mkdir factorioClusterio
|
||||||
RUN git clone -b dev https://github.com/Danielv123/factorioClusterio.git && cd factorioClusterio && npm install && curl -o factorio.tar.gz -L https://www.factorio.com/get-download/latest/headless/linux64 && tar -xvzf factorio.tar.gz
|
|
||||||
|
RUN git clone -b master https://github.com/Danielv123/factorioClusterio.git && cd factorioClusterio && npm install
|
||||||
|
RUN cd factorioClusterio && curl -o factorio.tar.gz -L https://www.factorio.com/get-download/latest/headless/linux64 && tar -xf factorio.tar.gz
|
||||||
|
|
||||||
WORKDIR factorioClusterio
|
WORKDIR factorioClusterio
|
||||||
RUN mkdir instances sharedMods sharedPlugins
|
RUN mkdir instances sharedMods
|
||||||
|
RUN cp config.json.dist config.json
|
||||||
|
|
||||||
RUN node client.js download
|
RUN node client.js download
|
||||||
|
|
||||||
LABEL maintainer "danielv@live.no"
|
LABEL maintainer "Sir3lit@gmail.com"
|
||||||
|
|
||||||
EXPOSE 8080 34167
|
EXPOSE 8080 34167
|
||||||
VOLUME /factorioClusterio/instances
|
VOLUME /factorioClusterio/instances
|
||||||
|
|||||||
@@ -45,11 +45,14 @@ const command = process.argv[2];
|
|||||||
// and as the process name in ps/top on linux.
|
// and as the process name in ps/top on linux.
|
||||||
process.title = "clusterioClient "+instance;
|
process.title = "clusterioClient "+instance;
|
||||||
|
|
||||||
|
// add better stack traces on promise rejection
|
||||||
|
process.on('unhandledRejection', r => console.log(r));
|
||||||
|
|
||||||
// make sure we have the master access token (can't write to master without it since clusterio 2.0)
|
// make sure we have the master access token (can't write to master without it since clusterio 2.0)
|
||||||
if(!config.masterAuthToken || typeof config.masterAuthToken !== "string"){
|
if(!config.masterAuthToken || typeof config.masterAuthToken !== "string"){
|
||||||
console.log("ERROR invalid config!");
|
console.error("ERROR invalid config!");
|
||||||
console.log("Master server now needs an access token for write operations. As clusterio slaves depends \
|
console.error("Master server now needs an access token for write operations. As clusterio slaves depends \
|
||||||
upon this, please add your token to config.js in the field named masterAuthToken. \
|
upon this, please add your token to config.json in the field named masterAuthToken. \
|
||||||
You can retrieve your auth token from the master in secret-api-token.txt after running it once.");
|
You can retrieve your auth token from the master in secret-api-token.txt after running it once.");
|
||||||
}
|
}
|
||||||
const needleOptionsWithTokenAuthHeader = {
|
const needleOptionsWithTokenAuthHeader = {
|
||||||
@@ -97,6 +100,7 @@ async function messageInterfaceInternal(command, callback, resolve, reject) {
|
|||||||
if(typeof callback == "function"){
|
if(typeof callback == "function"){
|
||||||
callback();
|
callback();
|
||||||
}
|
}
|
||||||
|
reject(err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -137,12 +141,12 @@ if (!command || command == "help" || command == "--help") {
|
|||||||
// create port colloumn
|
// create port colloumn
|
||||||
let factorioPorts = [];
|
let factorioPorts = [];
|
||||||
instanceNames.forEach(function(instance){
|
instanceNames.forEach(function(instance){
|
||||||
let factorioPort
|
let factorioPort;
|
||||||
|
|
||||||
if(instance.includes("Name:")){
|
if(instance.includes("Name:")){
|
||||||
factorioPort = "Port:"
|
factorioPort = "Port:"
|
||||||
} else {
|
} else {
|
||||||
factorioPort = require(config.instanceDirectory+"/"+instance+"/config").factorioPort;
|
factorioPort = require(path.resolve(config.instanceDirectory, instance, 'config')).factorioPort;
|
||||||
}
|
}
|
||||||
factorioPorts.push(factorioPort);
|
factorioPorts.push(factorioPort);
|
||||||
});
|
});
|
||||||
@@ -253,8 +257,8 @@ if (!command || command == "help" || command == "--help") {
|
|||||||
}).end();
|
}).end();
|
||||||
}
|
}
|
||||||
} else if (command == "start" && instance === undefined) {
|
} else if (command == "start" && instance === undefined) {
|
||||||
console.log("ERROR: No instanceName provided!");
|
console.error("ERROR: No instanceName provided!");
|
||||||
console.log("Usage: node client.js start [instanceName]");
|
console.error("Usage: node client.js start [instanceName]");
|
||||||
process.exit(0);
|
process.exit(0);
|
||||||
} else if (command == "start" && typeof instance == "string" && instance != "/" && !fs.existsSync(instancedirectory)) {
|
} else if (command == "start" && typeof instance == "string" && instance != "/" && !fs.existsSync(instancedirectory)) {
|
||||||
// if instance does not exist, create it
|
// if instance does not exist, create it
|
||||||
@@ -267,6 +271,11 @@ if (!command || command == "help" || command == "--help") {
|
|||||||
fs.writeFileSync(instancedirectory + "/script-output/txbuffer.txt", "");
|
fs.writeFileSync(instancedirectory + "/script-output/txbuffer.txt", "");
|
||||||
fs.mkdirSync(instancedirectory + "/mods/");
|
fs.mkdirSync(instancedirectory + "/mods/");
|
||||||
fs.mkdirSync(instancedirectory + "/instanceMods/");
|
fs.mkdirSync(instancedirectory + "/instanceMods/");
|
||||||
|
fs.mkdirSync(instancedirectory + "/scenarios/");
|
||||||
|
ncp("./lib/scenarios", path.resolve(instancedirectory, "scenarios"), err => {
|
||||||
|
if (err) console.error(err)
|
||||||
|
});
|
||||||
|
|
||||||
// fs.symlinkSync('../../../sharedMods', instancedirectory + "/mods", 'junction') // This is broken because it can only take a file as first argument, not a folder
|
// fs.symlinkSync('../../../sharedMods', instancedirectory + "/mods", 'junction') // This is broken because it can only take a file as first argument, not a folder
|
||||||
fs.writeFileSync(instancedirectory + `/config.ini`, `[path]\r\n
|
fs.writeFileSync(instancedirectory + `/config.ini`, `[path]\r\n
|
||||||
read-data=${ path.resolve(config.factorioDirectory, "data") }\r\n
|
read-data=${ path.resolve(config.factorioDirectory, "data") }\r\n
|
||||||
@@ -306,17 +315,48 @@ write-data=${ path.resolve(config.instanceDirectory, instance) }\r\n
|
|||||||
"autosave_slots": 5,
|
"autosave_slots": 5,
|
||||||
"afk_autokick_interval": 0,
|
"afk_autokick_interval": 0,
|
||||||
"auto_pause": config.auto_pause,
|
"auto_pause": config.auto_pause,
|
||||||
}
|
};
|
||||||
fs.writeFileSync(instancedirectory + "/server-settings.json", JSON.stringify(serversettings, null, 4));
|
fs.writeFileSync(instancedirectory + "/server-settings.json", JSON.stringify(serversettings, null, 4));
|
||||||
let createSave = child_process.spawnSync(
|
console.log("Server settings: "+JSON.stringify(serversettings, null, 4));
|
||||||
'./' + config.factorioDirectory + '/bin/x64/factorio', [
|
console.log("Creating save .....");
|
||||||
'-c', path.resolve(instancedirectory, 'config.ini'),
|
let factorio = child_process.spawn(
|
||||||
'--create', path.resolve(instancedirectory, 'saves', 'save.zip'),
|
'./' + config.factorioDirectory + '/bin/x64/factorio', [
|
||||||
]
|
'-c', instancedirectory + '/config.ini',
|
||||||
);
|
// '--create', instancedirectory + '/saves/save.zip',
|
||||||
console.log("Instance created!");
|
'--start-server-load-scenario', 'Hotpatch',
|
||||||
process.exit(0);
|
'--server-settings', instancedirectory + '/server-settings.json',
|
||||||
} else if (command == "start" && typeof instance == "string" && instance != "/" && fs.existsSync(instancedirectory)) {
|
'--rcon-port', Number(process.env.RCONPORT) || instconf.clientPort,
|
||||||
|
'--rcon-password', instconf.clientPassword,
|
||||||
|
], {
|
||||||
|
'stdio': ['pipe', 'pipe', 'pipe']
|
||||||
|
}
|
||||||
|
);
|
||||||
|
factorio.stdout.on("data", data => {
|
||||||
|
data = data.toString("utf8").replace(/(\r\n\t|\n|\r\t)/gm,"");
|
||||||
|
console.log(data);
|
||||||
|
if(data.includes("Starting RCON interface")){
|
||||||
|
let client = new Rcon();
|
||||||
|
client.connect({
|
||||||
|
host: 'localhost',
|
||||||
|
port: Number(process.env.RCONPORT) || instconf.clientPort,
|
||||||
|
password: instconf.clientPassword,
|
||||||
|
timeout: 5000
|
||||||
|
});
|
||||||
|
client.onDidAuthenticate(() => {
|
||||||
|
console.log('Clusterio | RCON Authenticated!');
|
||||||
|
});
|
||||||
|
client.onDidConnect(() => {
|
||||||
|
console.log('Clusterio | RCON Connected, starting save');
|
||||||
|
client.send("/c game.server_save('hotpachSave')");
|
||||||
|
});
|
||||||
|
}
|
||||||
|
if(data.includes("Saving finished")){
|
||||||
|
console.log("Map saved as hotpachSave.zip, exiting...");
|
||||||
|
console.log("Instance created!")
|
||||||
|
process.exit(0);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
} else if (command == "start" && typeof instance == "string" && instance != "/" && fs.existsSync(instancedirectory)){
|
||||||
// Exit if no instance specified (it should be, just a safeguard);
|
// Exit if no instance specified (it should be, just a safeguard);
|
||||||
if(instancedirectory != config.instanceDirectory+"/undefined"){
|
if(instancedirectory != config.instanceDirectory+"/undefined"){
|
||||||
var instanceconfig = require(path.resolve(instancedirectory,'config'));
|
var instanceconfig = require(path.resolve(instancedirectory,'config'));
|
||||||
@@ -344,7 +384,7 @@ write-data=${ path.resolve(config.instanceDirectory, instance) }\r\n
|
|||||||
fs.unlinkSync(path.join(instancedirectory,'factorio-current.log'));
|
fs.unlinkSync(path.join(instancedirectory,'factorio-current.log'));
|
||||||
} catch (err){
|
} catch (err){
|
||||||
if(err){
|
if(err){
|
||||||
console.log(err);
|
console.error(err);
|
||||||
} else {
|
} else {
|
||||||
console.log("Clusterio | Deleting old logs...");
|
console.log("Clusterio | Deleting old logs...");
|
||||||
}
|
}
|
||||||
@@ -390,16 +430,16 @@ write-data=${ path.resolve(config.instanceDirectory, instance) }\r\n
|
|||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
serverprocess.on('close', (code) => {
|
serverprocess.on('close', code => {
|
||||||
console.log(`child process exited with code ${code}`);
|
console.log(`child process exited with code ${code}`);
|
||||||
process.exit();
|
process.exit();
|
||||||
});
|
});
|
||||||
serverprocess.stdout.on("data", (data) => {
|
serverprocess.stdout.on("data", data => {
|
||||||
// log("Stdout: " + data);
|
// log("Stdout: " + data);
|
||||||
if(data.toString('utf8').includes("Couldn't parse RCON data: Maximum payload size exceeded")){
|
if(data.toString('utf8').includes("Couldn't parse RCON data: Maximum payload size exceeded")){
|
||||||
console.error("ERROR: RCON CONNECTION BROKE DUE TO TOO LARGE PACKET!");
|
console.error("ERROR: RCON CONNECTION BROKE DUE TO TOO LARGE PACKET!");
|
||||||
console.error("Attempting reconnect...");
|
console.error("Attempting reconnect...");
|
||||||
client.close();
|
client.disconnect();
|
||||||
client.connect();
|
client.connect();
|
||||||
}
|
}
|
||||||
// we have to do this to make logs visible on linux and in powershell. Causes log duplication for people with CMD.
|
// we have to do this to make logs visible on linux and in powershell. Causes log duplication for people with CMD.
|
||||||
@@ -418,7 +458,7 @@ write-data=${ path.resolve(config.instanceDirectory, instance) }\r\n
|
|||||||
// we read the log every 2 seconds and stop looping when we start connecting to factorio
|
// we read the log every 2 seconds and stop looping when we start connecting to factorio
|
||||||
function checkRcon() {
|
function checkRcon() {
|
||||||
fs.readFile(instancedirectory+"/factorio-current.log", function (err, data) {
|
fs.readFile(instancedirectory+"/factorio-current.log", function (err, data) {
|
||||||
// if (err) console.log(err);
|
// if (err) console.error(err);
|
||||||
if(data && data.indexOf('Starting RCON interface') > 0){
|
if(data && data.indexOf('Starting RCON interface') > 0){
|
||||||
client.connect({
|
client.connect({
|
||||||
host: 'localhost',
|
host: 'localhost',
|
||||||
@@ -464,17 +504,18 @@ write-data=${ path.resolve(config.instanceDirectory, instance) }\r\n
|
|||||||
// ensure instancemanagement only ever runs once
|
// ensure instancemanagement only ever runs once
|
||||||
_.once(instanceManagement);
|
_.once(instanceManagement);
|
||||||
function instanceManagement() {
|
function instanceManagement() {
|
||||||
/* Open websocket connection to master */
|
console.log("Started instanceManagement();");
|
||||||
|
|
||||||
|
/* Open websocket connection to master */
|
||||||
var socket = ioClient("http://"+config.masterIP+":"+config.masterPort);
|
var socket = ioClient("http://"+config.masterIP+":"+config.masterPort);
|
||||||
socket.on("hello", data => {
|
socket.on("hello", data => {
|
||||||
console.log("SOCKET | registering slave!");
|
console.log("SOCKET | registering slave!");
|
||||||
socket.emit("registerSlave", {
|
socket.emit("registerSlave", {
|
||||||
instanceID: instanceconfig.unique,
|
instanceID: instanceconfig.unique,
|
||||||
});
|
});
|
||||||
setInterval(B=> socket.emit("heartbeat"), 10000);
|
|
||||||
});
|
});
|
||||||
|
setInterval(B=> socket.emit("heartbeat"), 10000);
|
||||||
|
|
||||||
console.log("Started instanceManagement();");
|
|
||||||
// load plugins and execute onLoad event
|
// load plugins and execute onLoad event
|
||||||
let pluginDirectories = fileOps.getDirectoriesSync("./sharedPlugins/");
|
let pluginDirectories = fileOps.getDirectoriesSync("./sharedPlugins/");
|
||||||
let plugins = [];
|
let plugins = [];
|
||||||
@@ -486,7 +527,7 @@ function instanceManagement() {
|
|||||||
// these are our two config files. We need to send these in case plugin
|
// these are our two config files. We need to send these in case plugin
|
||||||
// wants to contact master or know something.
|
// wants to contact master or know something.
|
||||||
let combinedConfig = deepmerge(instanceconfig,config,{clone:true})
|
let combinedConfig = deepmerge(instanceconfig,config,{clone:true})
|
||||||
let pluginConfig = require("./sharedPlugins/" + pluginDirectories[i] + "/config.js");
|
let pluginConfig = require("./sharedPlugins/" + pluginDirectories[i] + "/config.js");
|
||||||
|
|
||||||
if(!global.subscribedFiles) {
|
if(!global.subscribedFiles) {
|
||||||
global.subscribedFiles = {};
|
global.subscribedFiles = {};
|
||||||
@@ -523,7 +564,11 @@ function instanceManagement() {
|
|||||||
console.log("Clusterio | Registered file subscription on "+instancedirectory + "/script-output/" + pluginConfig.scriptOutputFileSubscription);
|
console.log("Clusterio | Registered file subscription on "+instancedirectory + "/script-output/" + pluginConfig.scriptOutputFileSubscription);
|
||||||
fs.watch(instancedirectory + "/script-output/" + pluginConfig.scriptOutputFileSubscription, fileChangeHandler);
|
fs.watch(instancedirectory + "/script-output/" + pluginConfig.scriptOutputFileSubscription, fileChangeHandler);
|
||||||
// run once in case a plugin wrote out information before the plugin loaded fully
|
// run once in case a plugin wrote out information before the plugin loaded fully
|
||||||
fileChangeHandler(false, pluginConfig.scriptOutputFileSubscription);
|
|
||||||
|
// delay, so the socket got enough time to connect
|
||||||
|
setTimeout(()=> {
|
||||||
|
fileChangeHandler(false, pluginConfig.scriptOutputFileSubscription);
|
||||||
|
}, 500);
|
||||||
|
|
||||||
// send file contents to plugin for processing
|
// send file contents to plugin for processing
|
||||||
function fileChangeHandler(eventType, filename) {
|
function fileChangeHandler(eventType, filename) {
|
||||||
@@ -541,7 +586,7 @@ function instanceManagement() {
|
|||||||
if(stuff[i] && !stuff[i].includes('\u0000\u0000')) {
|
if(stuff[i] && !stuff[i].includes('\u0000\u0000')) {
|
||||||
try{
|
try{
|
||||||
plugins[I].scriptOutput(stuff[i]);
|
plugins[I].scriptOutput(stuff[i]);
|
||||||
}catch(e){console.log(e)}
|
}catch(e){console.error(e)}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -615,7 +660,7 @@ function instanceManagement() {
|
|||||||
} else {
|
} else {
|
||||||
// This plugin doesn't have a client portion
|
// This plugin doesn't have a client portion
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// world IDs ------------------------------------------------------------------
|
// world IDs ------------------------------------------------------------------
|
||||||
hashMods(instance, function(modHashes){
|
hashMods(instance, function(modHashes){
|
||||||
@@ -644,11 +689,14 @@ function instanceManagement() {
|
|||||||
console.log("Registered our presence with master "+config.masterIP+" at " + payload.time);
|
console.log("Registered our presence with master "+config.masterIP+" at " + payload.time);
|
||||||
needle.post(config.masterIP + ":" + config.masterPort + '/api/getID', payload, needleOptionsWithTokenAuthHeader, function (err, response, body) {
|
needle.post(config.masterIP + ":" + config.masterPort + '/api/getID', payload, needleOptionsWithTokenAuthHeader, function (err, response, body) {
|
||||||
if (err && err.code != "ECONNRESET"){
|
if (err && err.code != "ECONNRESET"){
|
||||||
console.error("We got problems, something went wrong when contacting master");
|
console.error("We got problems, something went wrong when contacting master"+config.masterIP+" at " + payload.time);
|
||||||
console.error(err);
|
console.error(err);
|
||||||
} else if (response && response.body) {
|
} else if (response && response.body) {
|
||||||
// In the future we might be interested in whether or not we actually manage to send it, but honestly I don't care.
|
// In the future we might be interested in whether or not we actually manage to send it, but honestly I don't care.
|
||||||
console.log(response.body);
|
if(response.body !== "ok") {
|
||||||
|
console.log("Got no \"ok\" while registering our precense with master "+config.masterIP+" at " + payload.time);
|
||||||
|
console.log(response.body);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -673,7 +721,7 @@ function instanceManagement() {
|
|||||||
hash: modHashes[i].hash,
|
hash: modHashes[i].hash,
|
||||||
}
|
}
|
||||||
needle.post(config.masterIP + ":" + config.masterPort + '/api/checkMod', payload, needleOptionsWithTokenAuthHeader, function (err, response, body) {
|
needle.post(config.masterIP + ":" + config.masterPort + '/api/checkMod', payload, needleOptionsWithTokenAuthHeader, function (err, response, body) {
|
||||||
if(err) console.log(new Error("Unable to contact master server! Please check your config.json."));
|
if(err) console.error("Unable to contact master server /api/checkMod! Please check your config.json.");
|
||||||
if(response && body && body == "found") {
|
if(response && body && body == "found") {
|
||||||
console.log("master has mod "+modHashes[i].modName);
|
console.log("master has mod "+modHashes[i].modName);
|
||||||
} else if (response && body && typeof body == "string") {
|
} else if (response && body && typeof body == "string") {
|
||||||
@@ -688,7 +736,7 @@ function instanceManagement() {
|
|||||||
},
|
},
|
||||||
}, function (err, resp, body) {
|
}, function (err, resp, body) {
|
||||||
if (err) {
|
if (err) {
|
||||||
console.log(new Error("Unable to contact master server! Please check your config.json."));
|
console.error(new Error("Unable to contact master server /api/uploadMod! Please check your config.json."));
|
||||||
} else {
|
} else {
|
||||||
console.log('URL: ' + body);
|
console.log('URL: ' + body);
|
||||||
}
|
}
|
||||||
@@ -867,7 +915,7 @@ function instanceManagement() {
|
|||||||
setInterval(function () {
|
setInterval(function () {
|
||||||
needle.get(config.masterIP + ":" + config.masterPort + '/api/inventory', function (err, response, body) {
|
needle.get(config.masterIP + ":" + config.masterPort + '/api/inventory', function (err, response, body) {
|
||||||
if(err){
|
if(err){
|
||||||
console.log("Unable to get JSON master/api/inventory, master might be unaccessible");
|
console.error("Unable to get JSON master/api/inventory, master might be unaccessible");
|
||||||
} else if (response && response.body) {
|
} else if (response && response.body) {
|
||||||
// Take the inventory we (hopefully) got and turn it into the format LUA accepts
|
// Take the inventory we (hopefully) got and turn it into the format LUA accepts
|
||||||
if(Buffer.isBuffer(response.body)) {console.log(response.body.toString("utf-8")); throw new Error();} // We are probably contacting the wrong webserver
|
if(Buffer.isBuffer(response.body)) {console.log(response.body.toString("utf-8")); throw new Error();} // We are probably contacting the wrong webserver
|
||||||
|
|||||||
Generated
-9638
File diff suppressed because it is too large.
Load diff
+7
-3
@@ -10,7 +10,9 @@
|
|||||||
"cover": "./node_modules/.bin/istanbul cover ./node_modules/mocha/bin/_mocha -- \"./{{,node_modules/_app/**/},!(node_modules)/**/}*.spec.js\" -R spec || echo . && codecov -t f7b38085-36eb-4d72-84e6-64721910171e",
|
"cover": "./node_modules/.bin/istanbul cover ./node_modules/mocha/bin/_mocha -- \"./{{,node_modules/_app/**/},!(node_modules)/**/}*.spec.js\" -R spec || echo . && codecov -t f7b38085-36eb-4d72-84e6-64721910171e",
|
||||||
"docs": "documentation build index.js --config documentation.yml -f html -o docs",
|
"docs": "documentation build index.js --config documentation.yml -f html -o docs",
|
||||||
"livedocs": "documentation serve --watch *.js lib/** --config documentation.yml",
|
"livedocs": "documentation serve --watch *.js lib/** --config documentation.yml",
|
||||||
"install": "node lib/npmPostinstall.js"
|
"install": "node lib/npmPostinstall.js",
|
||||||
|
"snyk-protect": "snyk protect",
|
||||||
|
"prepare": "npm run snyk-protect"
|
||||||
},
|
},
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"factorio"
|
"factorio"
|
||||||
@@ -63,7 +65,8 @@
|
|||||||
"socket.io": "^2.0.4",
|
"socket.io": "^2.0.4",
|
||||||
"socket.io-client": "^2.0.4",
|
"socket.io-client": "^2.0.4",
|
||||||
"sync-request": "^4.0.1",
|
"sync-request": "^4.0.1",
|
||||||
"underscore": "^1.8.3"
|
"underscore": "^1.8.3",
|
||||||
|
"snyk": "^1.88.0"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"documentation": "^5.4.0",
|
"documentation": "^5.4.0",
|
||||||
@@ -74,5 +77,6 @@
|
|||||||
"nock": "^9.1.6",
|
"nock": "^9.1.6",
|
||||||
"sinon": "^2.4.1",
|
"sinon": "^2.4.1",
|
||||||
"supertest": "^3.0.0"
|
"supertest": "^3.0.0"
|
||||||
}
|
},
|
||||||
|
"snyk": true
|
||||||
}
|
}
|
||||||
Reference in new issue
Block a user