# Docker images by singularity

**URL:** https://community.freefem.org/t/docker-images-by-singularity/950
**Category:** General Discussion
**Created:** [April 27, 2021, 6:27pm UTC](https://community.freefem.org/t/docker-images-by-singularity/950 "2021-04-27T18:27:35Z")
**Posts on this page:** 9
**Page:** 1

<div class="post-metadata">

### Author: ![yongxing](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/yongxing/32/3632_2.png) [@yongxing](https://community.freefem.org/u/yongxing)
#### Post date: [April 27, 2021, 6:27pm UTC](https://community.freefem.org/t/docker-images-by-singularity/950/1 "2021-04-27T18:27:35Z")

</div>

Dear all,

Did someone run FreeFEM using singularity?  
I tried:

singularity build --sandbox freefem docker://freefem/freefem  
singularity run freefem

and came across the following error:

ls: cannot access ‘/data/\*.edp’: No such file or directory

So what’s the right steps to run a docker image? Unfortunately my ARC system only has singularity installed (not docker engine).

Best,  
Yongxing.

---

<div class="post-metadata">

### Author: ![prj](https://avatars.discourse-cdn.com/v4/letter/p/ecae2f/32.png) [@prj](https://community.freefem.org/u/prj)
#### Post date: [April 27, 2021, 7:05pm UTC](https://community.freefem.org/t/docker-images-by-singularity/950/2 "2021-04-27T19:05:48Z")

</div>

I think it’s working, you just don’t have any `.edp` file in the container folder `/data`.

---

<div class="post-metadata">

### Author: ![yongxing](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/yongxing/32/3632_2.png) [@yongxing](https://community.freefem.org/u/yongxing)
#### Post date: [April 28, 2021, 5:02pm UTC](https://community.freefem.org/t/docker-images-by-singularity/950/3 "2021-04-28T17:02:01Z")

</div>

Thank you prj.  
I tried the following to specify the .edp file explicitly:

./ff.sif ./test.edp  
FATAL: permission denied

Andy idea about this error?

Best,  
Yongxing.

---

<div class="post-metadata">

### Author: ![prj](https://avatars.discourse-cdn.com/v4/letter/p/ecae2f/32.png) [@prj](https://community.freefem.org/u/prj)
#### Post date: [April 28, 2021, 5:08pm UTC](https://community.freefem.org/t/docker-images-by-singularity/950/4 "2021-04-28T17:08:12Z")

</div>

No, sorry, I don’t use singularity containers.

---

<div class="post-metadata">

### Author: ![LiudasD](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/liudasd/32/523_2.png) [@LiudasD](https://community.freefem.org/u/LiudasD)
#### Post date: [April 28, 2021, 8:02pm UTC](https://community.freefem.org/t/docker-images-by-singularity/950/5 "2021-04-28T20:02:41Z")

</div>

You have to look closely to docker image you are about to run.  
Dockerfile at the very end has this commands:

```
# Default command
ENV GLOB *.edp
CMD ["bash", "-c", "ls /data/$GLOB | xargs -I {} /usr/freefem/bin/ff-mpirun -n 1 {}"]

```

So it means, that if you run freefem container without any arguments it will automatically look for \*.edp files in _/data/_ folder.

Example provided with docker mounts local directory to /data/ folder inside container

`docker run -v $(pwd):/data freefem`

So you have to do the same with singularity

---

<div class="post-metadata">

### Author: ![yongxing](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/yongxing/32/3632_2.png) [@yongxing](https://community.freefem.org/u/yongxing)
#### Post date: [May 5, 2021, 8:55am UTC](https://community.freefem.org/t/docker-images-by-singularity/950/6 "2021-05-05T08:55:05Z")

</div>

Thank you very much! This works perfect for me. Can I ask one more question:

In the FreeFem container, can I run a parallel FreeFEM code directly? All the dependent libraries have already been configured in the container?

Best,  
Yongxing.

---

<div class="post-metadata">

### Author: ![prj](https://avatars.discourse-cdn.com/v4/letter/p/ecae2f/32.png) [@prj](https://community.freefem.org/u/prj)
#### Post date: [May 5, 2021, 10:39am UTC](https://community.freefem.org/t/docker-images-by-singularity/950/7 "2021-05-05T10:39:14Z")

</div>

Yes, you should be able to. Let me know if this is not the case.

---

<div class="post-metadata">

### Author: ![yongxing](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/yongxing/32/3632_2.png) [@yongxing](https://community.freefem.org/u/yongxing)
#### Post date: [June 30, 2021, 7:57am UTC](https://community.freefem.org/t/docker-images-by-singularity/950/8 "2021-06-30T07:57:01Z")

</div>

Dear LiudasD,

It seems I cannot pull the latest version v4.9 using the following command:

singularity pull ff.sif docker://freefem/freefem

I tried v4.9 for Windows and it worked well. How can I pull the docker image of v4.9?

Best,  
Yongxing.

---

<div class="post-metadata">

### Author: ![yongxing](https://yyz2.discourse-cdn.com/flex030/user_avatar/community.freefem.org/yongxing/32/3632_2.png) [@yongxing](https://community.freefem.org/u/yongxing)
#### Post date: [June 30, 2021, 7:58am UTC](https://community.freefem.org/t/docker-images-by-singularity/950/9 "2021-06-30T07:58:03Z")

</div>

Good morning,

It seems I cannot pull the latest version v4.9 using the following command:

singularity pull ff.sif docker://freefem/freefem

I tried v4.9 for Windows and it worked well. Howe can I pull the docker image of v4.9?

Best,  
Yongxing.
