Skip to content

create-usb-image-from-iso does not work anymore as non-root

By mistake I’ve run the script as non-root and I see:

INFO:__main__:Executing 'mlabel -i /dev/loop0p1 -N a69020d2 ::Tails'
Can't open /dev/loop0p1: Permission denied

Adding as_root=True is not enough because pkexec will filter out the MTOOLS_SKIP_CHECK environment variable.

IIRC the only reason why we’ve kept this code is that you wanted to run it this way. Is this still the case? The fact we’ve introduced a regression without spotting it suggests it’s not. I don’t care much personally about the support for running this script as non-root, but if we keep the corresponding code, then IMO it must be tested and maintained, otherwise we should just drop it, which would be an acceptable resolution for this ticket IMO.

Feature Branch: feature/15292-generate-usb-image

Parent Task: #15293 (closed)

Original created by @intrigeri on 16176 (Redmine)

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information