Apply old udev handling like core container (#2511)

This commit is contained in:
Pascal Vizeli 2021-02-03 12:56:25 +01:00 committed by GitHub
parent 7ad22e0399
commit 49ca923e51
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3,15 +3,16 @@
# Start udev service
# ==============================================================================
if bashio::fs.directory_exists /run/udev; then
if bashio::fs.directory_exists /run/udev && ! bashio::fs.file_exists /run/.old_udev; then
bashio::log.info "Using udev information from host"
bashio::exit.ok
fi
bashio::log.info "Setup udev backend inside container"
udevd --daemon
bashio::log.info "Update udev information"
touch /run/.old_udev
if udevadm trigger; then
udevadm settle || true
else