Update: July 26, 2019
This section of the forum is no longer actively monitored. We are working on a support migration plan that we will share here shortly. Apologies for this inconvenience.

Can I put variable in configuration file (for backend)

Hello everyone.

In my user case, I would like to use Singularity container software with WDL scripts via Cromwell.
I want to know if it is possible to put variable in my cromwell configuation file ?

I mean, in the following configuration :

backend {
    default = "Singularity"
    providers {
        Singularity { 
            actor-factory = "cromwell.backend.impl.sfs.config.ConfigBackendLifecycleActorFactory"
            config {
                run-in-background = true
                runtime-attributes = """
                String? singularity_img = "/path/to/singularity/img"
                submit = "singularity exec ${singularity_img} /bin/bash < ${script}"

Is it possible to replace singularity_img variable by string present in WDL script or Workflowinput file ? or by another way?



Best Answers

  • staaanstaaan
    Accepted Answer

    I tried to replace
    String? singularity = "/path/to/singularity/img"
    String? singularity
    and put these lines in my WDL script :
    runtime {
    singularity: "/path/to/singularity/img"

    but it don't works, I have this error message :

    Unrecognized runtime attribute keys: singularity

  • staaanstaaan
    Accepted Answer

    Hey, actually it works very well after my second post (with runtime) with API.
    thanks :)


Sign In or Register to comment.