Skip to content

Commit 09044d6

Browse files
author
Mrunal Patel
committed
Merge pull request #2 from wking/drop-runtime-supplied-devices-and-mounts
generate: Drop devices and mounts
2 parents 07b481e + 080ee00 commit 09044d6

File tree

1 file changed

+2
-64
lines changed

1 file changed

+2
-64
lines changed

generate.go

Lines changed: 2 additions & 64 deletions
Original file line numberDiff line numberDiff line change
@@ -619,32 +619,7 @@ func getDefaultTemplate() specs.LinuxSpec {
619619
Cwd: "/",
620620
},
621621
Hostname: "shell",
622-
Mounts: []specs.Mount{
623-
{
624-
Destination: "/proc",
625-
Type: "proc",
626-
Source: "proc",
627-
Options: nil,
628-
},
629-
{
630-
Destination: "/dev/pts",
631-
Type: "devpts",
632-
Source: "devpts",
633-
Options: []string{"nosuid", "noexec", "newinstance", "ptmxmode=0666", "mode=0620", "gid=5"},
634-
},
635-
{
636-
Destination: "/dev/shm",
637-
Type: "tmpfs",
638-
Source: "shm",
639-
Options: []string{"nosuid", "noexec", "nodev", "mode=1777", "size=65536k"},
640-
},
641-
{
642-
Destination: "/sys",
643-
Type: "sysfs",
644-
Source: "sysfs",
645-
Options: []string{"nosuid", "noexec", "nodev"},
646-
},
647-
},
622+
Mounts: []specs.Mount{},
648623
},
649624
Linux: specs.Linux{
650625
Capabilities: []string{
@@ -687,44 +662,7 @@ func getDefaultTemplate() specs.LinuxSpec {
687662
Soft: uint64(1024),
688663
},
689664
},
690-
Devices: []specs.Device{
691-
{
692-
Type: 'c',
693-
Path: "/dev/null",
694-
Major: 1,
695-
Minor: 3,
696-
},
697-
{
698-
Type: 'c',
699-
Path: "/dev/random",
700-
Major: 1,
701-
Minor: 8,
702-
},
703-
{
704-
Type: 'c',
705-
Path: "/dev/full",
706-
Major: 1,
707-
Minor: 7,
708-
},
709-
{
710-
Type: 'c',
711-
Path: "/dev/tty",
712-
Major: 5,
713-
Minor: 0,
714-
},
715-
{
716-
Type: 'c',
717-
Path: "/dev/zero",
718-
Major: 1,
719-
Minor: 5,
720-
},
721-
{
722-
Type: 'c',
723-
Path: "/dev/urandom",
724-
Major: 1,
725-
Minor: 9,
726-
},
727-
},
665+
Devices: []specs.Device{},
728666
},
729667
}
730668

0 commit comments

Comments
 (0)