Makie - How to serve WGLMakie visualizations on Docker image?

I am preparing material for the upcoming JuliaEO2023 workshop, and would like to use WGLMakie on the docker image shared by @gaelforget. I understand that I need to map the port where Makie displays visualizations.

I tried mapping the port 8000 to the docker container with:

sudo docker run -p 8888:8888 -p 8000:8000 gaelforget/notebooks:latest

and then tried adding the following JSServe page to a fresh Pluto notebook:

port = parse(Int, get(ENV,  "JS_SERVE_PORT", "8000"))

using JSServe
Page(listen_port = port)

When I import WGLMakie and try to plot, the visualization doesn’t display. An error message mentions that this is probably an issue with JSServe. The same notebook works fine on my host machine. Can anyone help with this? cc: @sdanisch @jules

Seems to work for me with the latest update to the Docker build and just

docker run -p 8888:8888 gaelforget/notebooks:latest

By “work” I mean that I can “using WGLMakie” succeeds and plots display in Pluto (& jupyter). I have not tried animating a plot or anything like that though.

Just in case : WGLMakie

update : I have now added WGLMakie to the Docker image

1 Like

Indeed, it only works with the latest release of JSServe and Makie. @sdanisch pushing it forward ! thanks.