Skip to content
Snippets Groups Projects
Commit 218a6116 authored by Skander Hatira's avatar Skander Hatira
Browse files

Building

parent 1241296e
No related branches found
No related tags found
No related merge requests found
......@@ -125,6 +125,7 @@
"json2csv": "^5.0.6",
"jsonwebtoken": "^8.5.1",
"jwt-decode": "^3.1.2",
"kill-port": "^1.6.1",
"material-ui": "^0.20.2",
"mongodb": "^3.6.4",
"mongoose": "^5.11.15",
......
......@@ -110,13 +110,7 @@ export default function GlobalConfig() {
[e.target.id]: newValue,
});
};
const handleCluster = (e) => {
setRunState({
...runState,
[e.target.name]: String(e.target.checked),
outdir: runState.cluster ? "remote" : path.dirname(runState.genome),
});
};
console.log(runState.remoteDir);
console.log(value);
......
......@@ -17,6 +17,8 @@ import Typography from "@material-ui/core/Typography";
import IconButton from "@material-ui/core/IconButton";
import Container from "@material-ui/core/Container";
const kill = require("kill-port");
const running = require("is-running");
const handler = require("serve-handler");
const electron = window.require("electron");
const { shell } = window.require("electron");
......@@ -351,32 +353,37 @@ export default function VisualizationFill() {
console.log(result);
const handleServe = () => {
try {
const server = http.createServer(async (request, response) => {
await handler(request, response, {
public: user.user.jbPath,
});
const server = http.createServer(async (request, response) => {
handler(request, response, {
public: user.user.jbPath,
});
console.log(user.user.jbPath);
server.listen(user.user.port[0], () => {});
} catch (err) {
portastic
.find({
min: 30000,
max: 35000,
retrieve: 1,
})
.then(function (port) {
const server = http.createServer(async (request, response) => {
await handler(request, response, {
public: user.user.jbPath,
});
});
server.listen(user.user.port[0], () => {});
shell.openExternal(`http:///localhost:${port}`);
});
}
shell.openExternal(`http:///localhost:${user.user.port[0]}`);
});
server.listen(user.user.port[0], () => {
console.log(server.listening);
shell.openExternal(`http:///localhost:${user.user.port[0]}`);
});
server.on("error", (err) => {
console.log(err);
});
// portastic
// .find({
// min: 30000,
// max: 35000,
// retrieve: 1,
// })
// .then(function (port) {
// const server = http.createServer(async (request, response) => {
// await handler(request, response, {
// public: user.user.jbPath,
// });
// });
// server.listen(user.user.port[0], () => {});
// shell.openExternal(`http:///localhost:${port}`);
// });
// }
};
return (
<Container maxWidth="lg" className={classes.container} gutterbottom>
......
......@@ -8753,6 +8753,11 @@ get-stream@^5.0.0, get-stream@^5.1.0:
dependencies:
pump "^3.0.0"
 
get-them-args@1.3.2:
version "1.3.2"
resolved "https://registry.yarnpkg.com/get-them-args/-/get-them-args-1.3.2.tgz#74a20ba8a4abece5ae199ad03f2bcc68fdfc9ba5"
integrity sha1-dKILqKSr7OWuGZrQPyvMaP38m6U=
get-value@^2.0.3, get-value@^2.0.6:
version "2.0.6"
resolved "https://registry.yarnpkg.com/get-value/-/get-value-2.0.6.tgz#dc15ca1c672387ca76bd37ac0a395ba2042a2c28"
......@@ -11333,6 +11338,14 @@ keyv@^4.0.0:
dependencies:
json-buffer "3.0.1"
 
kill-port@^1.6.1:
version "1.6.1"
resolved "https://registry.yarnpkg.com/kill-port/-/kill-port-1.6.1.tgz#560fe79484583bdf3a5e908557dae614447618aa"
integrity sha512-un0Y55cOM7JKGaLnGja28T38tDDop0AQ8N0KlAdyh+B1nmMoX8AnNmqPNZbS3mUMgiST51DCVqmbFT1gNJpVNw==
dependencies:
get-them-args "1.3.2"
shell-exec "1.0.2"
killable@^1.0.1:
version "1.0.1"
resolved "https://registry.yarnpkg.com/killable/-/killable-1.0.1.tgz#4c8ce441187a061c7474fb87ca08e2a638194892"
......@@ -16604,6 +16617,11 @@ shebang-regex@^3.0.0:
resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172"
integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==
 
shell-exec@1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/shell-exec/-/shell-exec-1.0.2.tgz#2e9361b0fde1d73f476c4b6671fa17785f696756"
integrity sha512-jyVd+kU2X+mWKMmGhx4fpWbPsjvD53k9ivqetutVW/BQ+WIZoDoP4d8vUMGezV6saZsiNoW2f9GIhg9Dondohg==
shell-quote@1.7.2:
version "1.7.2"
resolved "https://registry.yarnpkg.com/shell-quote/-/shell-quote-1.7.2.tgz#67a7d02c76c9da24f99d20808fcaded0e0e04be2"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment