Answer the question
In order to leave comments, you need to log in
How to mount device in lxc without reboot?
I created a container for esp32 programming and for this I wrote in the config:
lxc.mount.entry = /dev/ttyUSB0 dev/ttyUSB0 none bind,optional,create=file
Answer the question
In order to leave comments, you need to log in
By trial and error, inspired by this manual https://discuss.linuxcontainers.org/t/live-usb-mou... found a solution. Xs, how it works, but it works:
create a dev directory in the hamster (you can in another place):
write in the container config:
where lxcuser is the user under which lxc is run
Create a symbol file with the command:
Update the device with the command:
sudo umount /home/lxcuser/dev/ttyUSB0 && \
sudo mount --bind /dev/ttyUSB0 /home/lxcuser/dev/ttyUSB0 && \
sudo chmod 666 /home/lxcuser/dev/ttyUSB0
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question