@@ -92,7 +92,7 @@ var syscontMounts = []specs.Mount{
92
92
// Container mounts virtualized by sysbox-fs
93
93
//
94
94
// TODO: in the future get these from sysbox-fs via grpc
95
- var sysboxFsMounts = []specs.Mount {
95
+ var SysboxfsMounts = []specs.Mount {
96
96
//
97
97
// procfs mounts
98
98
//
@@ -532,7 +532,7 @@ func cfgMounts(spec *specs.Spec, sysbox *sysbox.Sysbox) error {
532
532
}
533
533
534
534
if sysFs .Enabled () {
535
- cfgSysboxFsMounts (spec , sysFs )
535
+ cfgSysboxfsMounts (spec , sysFs )
536
536
}
537
537
538
538
if sysMgr .Enabled () {
@@ -644,20 +644,20 @@ func cfgSyscontMountsReadOnly(sysMgr *sysbox.Mgr, spec *specs.Spec) {
644
644
spec .Mounts = append (spec .Mounts , tmpMounts ... )
645
645
}
646
646
647
- // cfgSysboxFsMounts adds the sysbox-fs mounts to the container's config.
648
- func cfgSysboxFsMounts (spec * specs.Spec , sysFs * sysbox.Fs ) {
647
+ // cfgSysboxfsMounts adds the sysbox-fs mounts to the container's config.
648
+ func cfgSysboxfsMounts (spec * specs.Spec , sysFs * sysbox.Fs ) {
649
649
650
- spec .Mounts = utils .MountSliceRemove (spec .Mounts , sysboxFsMounts , func (m1 , m2 specs.Mount ) bool {
650
+ spec .Mounts = utils .MountSliceRemove (spec .Mounts , SysboxfsMounts , func (m1 , m2 specs.Mount ) bool {
651
651
return m1 .Destination == m2 .Destination
652
652
})
653
653
654
- // Adjust sysboxFsMounts path attending to container-id value.
654
+ // Adjust SysboxfsMounts path attending to container-id value.
655
655
cntrMountpoint := filepath .Join (sysFs .Mountpoint , sysFs .Id )
656
656
657
- for i := range sysboxFsMounts {
658
- sysboxFsMounts [i ].Source =
657
+ for i := range SysboxfsMounts {
658
+ SysboxfsMounts [i ].Source =
659
659
strings .Replace (
660
- sysboxFsMounts [i ].Source ,
660
+ SysboxfsMounts [i ].Source ,
661
661
SysboxFsDir ,
662
662
cntrMountpoint ,
663
663
1 ,
@@ -675,12 +675,12 @@ func cfgSysboxFsMounts(spec *specs.Spec, sysFs *sysbox.Fs) {
675
675
// remounted to read-only after the container setup completes, right before
676
676
// starting the container's init process.
677
677
if spec .Root .Readonly {
678
- for _ , m := range sysboxFsMounts {
678
+ for _ , m := range SysboxfsMounts {
679
679
spec .Linux .ReadonlyPaths = append (spec .Linux .ReadonlyPaths , m .Destination )
680
680
}
681
681
}
682
682
683
- spec .Mounts = append (spec .Mounts , sysboxFsMounts ... )
683
+ spec .Mounts = append (spec .Mounts , SysboxfsMounts ... )
684
684
}
685
685
686
686
// cfgSystemdMounts adds systemd related mounts to the spec
0 commit comments