diff --git a/webapp/server/crons/pipelineMonitor.js b/webapp/server/crons/pipelineMonitor.js index 9f7c1c41..5ce73325 100644 --- a/webapp/server/crons/pipelineMonitor.js +++ b/webapp/server/crons/pipelineMonitor.js @@ -163,10 +163,10 @@ async function generateInputs(proj_home, conf, proj) { const fileCode = path.basename(fq); let name = await common.getRealName(fileCode); const inputFq = inputDir + "/" + name; - if(!fs.existsSync(inputFq)) { + if (!fs.existsSync(inputFq)) { fs.symlinkSync(fq, inputFq, 'file'); + inputs.push(inputFq); } - inputs.push(inputFq); } else { inputs.push(fq); } @@ -191,8 +191,10 @@ async function generateInputs(proj_home, conf, proj) { const fileCode = path.basename(fq1); let name = await common.getRealName(fileCode); const inputFq = inputDir + "/" + name; - fs.symlinkSync(fq1, inputFq, 'file'); - inputs_fq1.push(inputFq); + if (!fs.existsSync(inputFq)) { + fs.symlinkSync(fq1, inputFq, 'file'); + inputs_fq1.push(inputFq); + } } else { inputs_fq1.push(fq1); } @@ -206,8 +208,10 @@ async function generateInputs(proj_home, conf, proj) { const fileCode = path.basename(fq2); let name = await common.getRealName(fileCode); const inputFq = inputDir + "/" + name; - fs.symlinkSync(fq2, inputFq, 'file'); - inputs_fq2.push(inputFq); + if (!fs.existsSync(inputFq)) { + fs.symlinkSync(fq2, inputFq, 'file'); + inputs_fq2.push(inputFq); + } } else { inputs_fq2.push(fq2); }