disk: implement Mountable interface for Filesystem

A filesystem obviously can be mounted, thus it implements the Mountable
interface.

Co-Authored-By: Christian Kellner <christian@kellner.me>
This commit is contained in:
Achilleas Koutsou 2022-02-07 19:58:14 +01:00 committed by Tom Gundersen
parent 4c34b5e2a8
commit 250116638c

View file

@ -48,3 +48,26 @@ func (fs *Filesystem) QEMUFilesystem() osbuild.QEMUFilesystem {
Mountpoint: fs.Mountpoint,
}
}
func (fs *Filesystem) GetMountpoint() string {
return fs.Mountpoint
}
func (fs *Filesystem) GetFSType() string {
return fs.Type
}
func (fs *Filesystem) GetFSSpec() FSSpec {
return FSSpec{
UUID: fs.UUID,
Label: fs.Label,
}
}
func (fs *Filesystem) GetFSTabOptions() FSTabOptions {
return FSTabOptions{
MntOps: fs.FSTabOptions,
Freq: fs.FSTabFreq,
PassNo: fs.FSTabPassNo,
}
}