Skip to content

Commit

Permalink
analysis: change workflow docker, #TASK-6445
Browse files Browse the repository at this point in the history
  • Loading branch information
pfurio committed Sep 30, 2024
1 parent d74a555 commit 14e6b6b
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -267,7 +267,7 @@ protected void run() throws Exception {
// Build output binding
AbstractMap.SimpleEntry<String, String> outputBinding = new AbstractMap.SimpleEntry<>(outDirPath, outDirPath);

String dockerImage = "opencb/opencga-workflow";
String dockerImage = "opencb/opencga-workflow:TASK-6445";
StringBuilder stringBuilder = new StringBuilder()
.append("bash -c \"NXF_VER=").append(workflow.getManager().getVersion()).append(" nextflow -c ").append(nextflowConfigPath).append(" run ");
if (workflow.getRepository() != null && StringUtils.isNotEmpty(workflow.getRepository().getImage())) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
import java.io.InputStream;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashMap;
import java.util.Map;
Expand Down Expand Up @@ -83,6 +84,20 @@ public void nextflowDockerTest() throws ToolException, CatalogException, IOExcep
WorkflowCreateParams workflow = new WorkflowCreateParams()
.setId("workflow")
.setType(Workflow.Type.OTHER)
.setVariables(Arrays.asList(
new WorkflowVariable()
.setId("outdir")
.setOutput(true)
.setRequired(true),
new WorkflowVariable()
.setId("genome")
.setRequired(true)
.setDefaultValue("GRCh37"),
new WorkflowVariable()
.setId("-profile")
.setRequired(true)
.setDefaultValue("docker")
))
.setRepository(new WorkflowRepository("nf-core/demo"));
catalogManager.getWorkflowManager().create(studyFqn, workflow.toWorkflow(), QueryOptions.empty(), ownerToken);

Expand All @@ -99,9 +114,9 @@ public void nextflowDockerTest() throws ToolException, CatalogException, IOExcep
NextFlowExecutor nextFlowExecutorTest = new NextFlowExecutor();
Map<String, String> cliParams = new HashMap<>();
cliParams.put("input", "file://samplesheet.csv");
cliParams.put("outdir", "$OUTPUT");
cliParams.put("genome", "GRCh37");
cliParams.put("-profile", "docker");
// cliParams.put("outdir", "$OUTPUT");
// cliParams.put("genome", "GRCh37");
// cliParams.put("-profile", "docker");
NextFlowRunParams runParams = new NextFlowRunParams(workflow.getId(), 1, cliParams);
ObjectMap params = runParams.toObjectMap();
params.put(ParamConstants.STUDY_PARAM, studyFqn);
Expand Down

0 comments on commit 14e6b6b

Please sign in to comment.