Hey, I am trying to solve a complex valued problem in a jupyter notebook. I have seen the discussion FEniCS on Apple silicon M1, but can’t get it to run with gmsh and multiple other preinstalled python packages.
Currently I am building my own container on-top of the dolfinx/lab-container. Here I install the python packages and other tools I need. Adding CMD source /usr/local/bin/dolfinx-complex-mode
makes the notebook unusable.
What am I doing wrong? What is the best way of doing this?
Thank you in Advance
I would do something like the following:
docker run -v $(pwd):/root/shared -w "/root/shared" --rm --env LD_LIBRARY_PATH=/usr/local/dolfinx-complex/lib --env PATH=/usr/local/dolfinx-complex/bin:/usr/local/gmsh-4.6.0-Linux64-sdk/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin --env PKG_CONFIG_PATH=/usr/local/dolfinx-complex/lib/pkgconfig --env PETSC_ARCH=linux-gnu-complex-32 --env PYTHONPATH=/usr/local/dolfinx-complex/lib/python3.8/dist-packages -p 8888:8888 dolfinx/lab
This sets the environment variables when creating the docker container.
You could also simply add these environment variables to the new dockerfile you are creating.
2 Likes