Hello,
I have the following problem trying to create a container request through the API.
The use case is that I want to run a workflow (that I have already run the first time through arvados-cwl-runner
). Upon reading the docs, I understand that I have to create a container request with its state
being Commited
.
Things like container_image
and container_uuid
I can find through the result page of the already run container. However, in the docs I also see that I have to set resources like cwd
and output_path
, which confuses me because I didnât do so using the cli tool and I canât find them anywhere (and thus set them randomly). When I use the following request, I get this error:
curl -k -X POST \
-H "Authorization: OAuth2 $ARVADOS_API_TOKEN" \
--data-urlencode container_request@/dev/stdin \
https://$ARVADOS_API_HOST/arvados/v1/container_requests/ \
<<EOF
{
"container_uuid":"x3dm2-dz642-ywxuzrw93j62vg9",
"container_image":"x3dm2-4zz18-59mq7hyzbu1rglu",
"state":"commited",
"cwd":"/",
"output_path":"/output",
"command":[
"arvados-cwl-runner",
"--local",
"--api=containers",
"--project-uuid=x3dm2-tpzed-amlr5fgf7gp7kgb",
"--collection-cache-size=256",
"/var/lib/cwl/workflow.json#main",
"/var/lib/cwl/cwl.input.json"
]
}
EOF
{"errors":["State cannot change from to uncommited (req-1k05gzz95byss1vt5b2i)","Container count cannot be modified in state 'uncommited' (0, 1) (req-1k05gzz95byss1vt5b2i)"],"error_token":"1594909570+49a14085"}%
Note that there is one extra space between from and to in the error message. I donât know what more it expects! Itâs supposedly a new container request, which happens to have the same uuid
as an existing one and, as a result, it should run using the old container!
PS: Something happened and I created the same topic twice, sorry!