OMA icon indicating copy to clipboard operation
OMA copied to clipboard

Improve Docker container

Open artur-sannikov opened this issue 1 year ago • 14 comments

Right now Docker container is very basic and cannot be used.

I managed to run in with Podman 4.8.3 :

podman pull https://github.com/js2264/OMA/pkgs/container/OMA
podman run --rm -p 8787:8787 <container_id>

It's then accessible on localhost:8787. Username root and password is given in shell.

There are no accessible files in RStudio web-interface. Inside the container there is a OMA_0.98.16.tar.gz archive.

BiocBook supports containerization, so it a Docker image might be nice to have because it can help avoid all dependency issues on different platforms and their versions people run.

artur-sannikov avatar Jan 10 '24 11:01 artur-sannikov

Thanks! We will take this into account

TuomasBorman avatar Jan 10 '24 12:01 TuomasBorman

You now need to run podman pull ghcr.io/js2264/oma:latest.

artur-sannikov avatar Apr 10 '24 12:04 artur-sannikov

@artur-sannikov is this ready?

antagomir avatar Jul 22 '24 13:07 antagomir

@antagomir, currently the most up-to-date container is on ghcr.io/microbiome/oma, but it's private and requires logging in with docker login ghcr.io. I just tried it on a fresh install of Fedora server and it fails at

[23/37] pages/multiassay_ordination.qmd


processing file: multiassay_ordination.qmd
  |..........................................               |  74% [mofa6]     Error in `py_get_attr()`:
! AttributeError: module 'mofapy2' has no attribute 'run.entry_point'
Run `reticulate::py_last_error()` for details.
Backtrace:
 1. MOFA2::run_mofa(model, use_basilisk = TRUE)
 2. basilisk::basiliskRun(...)
 3. MOFA2 (local) fun(...)
 4. MOFA2:::.run_mofa_reticulate(object, outfile, save_data)
 6. reticulate:::`$.python.builtin.module`(mofa, "run.entry_point")
 7. reticulate::py_get_attr(x, name, FALSE)



Quitting from lines 126-136 [mofa6] (multiassay_ordination.qmd)
                                                                                                       
Execution halted
Error in run_serve_daemon("preview", file, NULL, args, render, port, host,  : 
  Error starting quarto

Image ghcr.io/js2264/oma:latest is outdated.

artur-sannikov avatar Jul 23 '24 07:07 artur-sannikov

@artur-sannikov MOFA2 is causing this issue, but any idea why? Any idea how to fix this?

TuomasBorman avatar Jul 23 '24 07:07 TuomasBorman

I'm not even able to build an image on GitHub: https://github.com/artur-sannikov/OMA/actions/runs/10055341285/job/27791808192 because it fails due to API rate limiting (it's too big, I guess). I want to try standalone Docker build without relying on BiocBook.

artur-sannikov avatar Jul 23 '24 08:07 artur-sannikov

We need to install Python to solve this issue. Uncomment three lines here.

I opened #585.

artur-sannikov avatar Jul 26 '24 09:07 artur-sannikov

The #585 is merged now. Can we close this one as well @artur-sannikov ?

antagomir avatar Aug 05 '24 19:08 antagomir

@antagomir, the image ghcr.io/js2264/oma:latest is not built anymore. This image should be made public. We can then close. I'll open a PR to update README.

artur-sannikov avatar Aug 06 '24 09:08 artur-sannikov

If you can take care of closing this issue when it is ready that would be great.

antagomir avatar Aug 06 '24 16:08 antagomir

Someone with access to the container registry settings, needs to make the image public.

artur-sannikov avatar Aug 07 '24 05:08 artur-sannikov

That requires changing settings from organization level. Does it now work?

Another thing:

It seems that Docker is not working anymore since it exceeds the cache. I tried to fix it month ago (62d6764db15ddd052b4ed1199fec3bfbe1915631, d824b65de5b05ef7a939c8484febd14baf7c3525, 80a85411124dbb45bb3feab12510257d8cde0aa5, 4e80d2f1eea1a046959ad4f3a1b615d6af47b7bd, 988a78c6732402c35532dd85bd3ffd628d1e0fa2). It worked, but now it exceeds the limit again (Maybe new packages were added to OMA). See the GHA report: https://github.com/microbiome/OMA/actions/runs/10271529523/job/28421702599

Would you be able to fix this @artur-sannikov ? This is somewhat urgent since the run does not work and OMA is not updated. I would recommend involving BiocBook to this. This affects all BiocBook users and the guy might have some idea how to fix.

TuomasBorman avatar Aug 07 '24 05:08 TuomasBorman

We can probably afford extra space when necessary but it would be anyway good to minimize the loads.

antagomir avatar Aug 07 '24 06:08 antagomir

It took > 1 hour to build: https://github.com/artur-sannikov/OMA/actions/runs/10280588960/job/28448241727#step:12:8806, but the building part was successful. It was not pushed due to token permissions I think, but it's not a problem.

I think such long build time is due to miniconda installation to fix #585. I cannot build the image locally because I hit the API rate limit.

artur-sannikov avatar Aug 07 '24 11:08 artur-sannikov