mounts/org.osbuild.btrfs: add support for mounting subvolumes
Co-authored-by: Christian Kellner <christian@kellner.me>
This commit is contained in:
parent
724183b35c
commit
0952ae9933
2 changed files with 6 additions and 0 deletions
|
|
@ -37,6 +37,10 @@ SCHEMA_2 = """
|
|||
"description": "Don't load the journal on mounting",
|
||||
"type": "boolean",
|
||||
"default": false
|
||||
},
|
||||
"subvol": {
|
||||
"description": "Subvolume to be mounted",
|
||||
"type": "string"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -139,6 +139,8 @@ class FileSystemMountService(MountService):
|
|||
opts.append(f"umask={options['umask']}")
|
||||
if "shortname" in options:
|
||||
opts.append(f"shortname={options['shortname']}")
|
||||
if "subvol" in options:
|
||||
opts.append(f"subvol={options['subvol']}")
|
||||
if opts:
|
||||
return ["-o", ",".join(opts)]
|
||||
return []
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue