diff options
author | Fabricio Voznika <fvoznika@google.com> | 2018-09-07 12:27:44 -0700 |
---|---|---|
committer | Shentubot <shentubot@google.com> | 2018-09-07 12:28:48 -0700 |
commit | bc81f3fe4a042a15343d2eab44da32d818ac1ade (patch) | |
tree | 808e8e3ebfdf7e43b9f279032cd39e28fb75de98 /runsc/boot/config.go | |
parent | f895cb4d8b4b37a563b7a5b9dc92eae552084b44 (diff) |
Remove '--file-access=direct' option
It was used before gofer was implemented and it's not
supported anymore.
BREAKING CHANGE: proxy-shared and proxy-exclusive options
are now: shared and exclusive.
PiperOrigin-RevId: 212017643
Change-Id: If029d4073fe60583e5ca25f98abb2953de0d78fd
Diffstat (limited to 'runsc/boot/config.go')
-rw-r--r-- | runsc/boot/config.go | 31 |
1 files changed, 12 insertions, 19 deletions
diff --git a/runsc/boot/config.go b/runsc/boot/config.go index 28a1600cd..01da535af 100644 --- a/runsc/boot/config.go +++ b/runsc/boot/config.go @@ -60,28 +60,23 @@ func (p PlatformType) String() string { type FileAccessType int const ( - // FileAccessProxy sends IO requests to a Gofer process that validates the + // FileAccessShared sends IO requests to a Gofer process that validates the // requests and forwards them to the host. - FileAccessProxy FileAccessType = iota + FileAccessShared FileAccessType = iota - // FileAccessProxyExclusive is the same as FileAccessProxy, but enables + // FileAccessExclusive is the same as FileAccessShared, but enables // extra caching for improved performance. It should only be used if // the sandbox has exclusive access to the filesystem. - FileAccessProxyExclusive - - // FileAccessDirect connects the sandbox directly to the host filesystem. - FileAccessDirect + FileAccessExclusive ) // MakeFileAccessType converts type from string. func MakeFileAccessType(s string) (FileAccessType, error) { switch s { - case "proxy-shared": - return FileAccessProxy, nil - case "proxy-exclusive": - return FileAccessProxyExclusive, nil - case "direct": - return FileAccessDirect, nil + case "shared": + return FileAccessShared, nil + case "exclusive": + return FileAccessExclusive, nil default: return 0, fmt.Errorf("invalid file access type %q", s) } @@ -89,12 +84,10 @@ func MakeFileAccessType(s string) (FileAccessType, error) { func (f FileAccessType) String() string { switch f { - case FileAccessProxy: - return "proxy-shared" - case FileAccessProxyExclusive: - return "proxy-exclusive" - case FileAccessDirect: - return "direct" + case FileAccessShared: + return "shared" + case FileAccessExclusive: + return "exclusive" default: return fmt.Sprintf("unknown(%d)", f) } |