Enabling a virtual canbus device in docker

Hello,

I'm trying to set up a development environment with docker since I need a virtual canbus (vcan) device under windows.
I am using the latest docker image nodered/node-red:latest following the guide under documentation.

The plan is to use the "node-red-contrib-can" module but I would need to set up a virtual can interface.
I know the node-red docker is alpine linux based and I managed to install can-utils.
But I think the can module/kernel options are turned off.

When I run /usr/src/node-red # modprobe vcan
the result is
modprobe: FATAL: Module vcan not found in directory /lib/modules/5.15.146.1-microsoft-standard-WSL2

Would I need to build my own custom docker image (I did find some guide)?
Or is it something simple I am missing?

Note: I do not have an actual can device attached. I just need a virtual one in a docker container.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.