Remove dependency on tar2vhd for LCOW differ
This change no longer requires the use of a UtlityVM on Windows to convert the layer tar to an ext4 vhd for LCOW. This has a significant performance boost that makes linux/amd64 layer extraction comparable to native Linux performance. Signed-off-by: Justin Terry (VM) <juterry@microsoft.com>
This commit is contained in:
6
vendor/github.com/Microsoft/hcsshim/cmd/go-runhcs/runhcs.go
generated
vendored
6
vendor/github.com/Microsoft/hcsshim/cmd/go-runhcs/runhcs.go
generated
vendored
@@ -10,6 +10,7 @@ import (
|
||||
"strings"
|
||||
"sync"
|
||||
|
||||
irunhcs "github.com/Microsoft/hcsshim/internal/runhcs"
|
||||
"github.com/containerd/go-runc"
|
||||
)
|
||||
|
||||
@@ -23,8 +24,7 @@ const (
|
||||
// JSON is the JSON formatted log output.
|
||||
JSON Format = "json"
|
||||
|
||||
command = "runhcs"
|
||||
safePipePrefix = `\\.\pipe\ProtectedPrefix\Administrators\`
|
||||
command = "runhcs"
|
||||
)
|
||||
|
||||
var bytesBufferPool = sync.Pool{
|
||||
@@ -62,7 +62,7 @@ func (r *Runhcs) args() []string {
|
||||
out = append(out, "--debug")
|
||||
}
|
||||
if r.Log != "" {
|
||||
if strings.HasPrefix(r.Log, safePipePrefix) {
|
||||
if strings.HasPrefix(r.Log, irunhcs.SafePipePrefix) {
|
||||
out = append(out, "--log", r.Log)
|
||||
} else {
|
||||
abs, err := filepath.Abs(r.Log)
|
||||
|
||||
5
vendor/github.com/Microsoft/hcsshim/cmd/go-runhcs/runhcs_create.go
generated
vendored
5
vendor/github.com/Microsoft/hcsshim/cmd/go-runhcs/runhcs_create.go
generated
vendored
@@ -6,6 +6,7 @@ import (
|
||||
"path/filepath"
|
||||
"strings"
|
||||
|
||||
irunhcs "github.com/Microsoft/hcsshim/internal/runhcs"
|
||||
runc "github.com/containerd/go-runc"
|
||||
)
|
||||
|
||||
@@ -32,7 +33,7 @@ func (opt *CreateOpts) args() ([]string, error) {
|
||||
out = append(out, "--pid-file", abs)
|
||||
}
|
||||
if opt.ShimLog != "" {
|
||||
if strings.HasPrefix(opt.ShimLog, safePipePrefix) {
|
||||
if strings.HasPrefix(opt.ShimLog, irunhcs.SafePipePrefix) {
|
||||
out = append(out, "--shim-log", opt.ShimLog)
|
||||
} else {
|
||||
abs, err := filepath.Abs(opt.ShimLog)
|
||||
@@ -43,7 +44,7 @@ func (opt *CreateOpts) args() ([]string, error) {
|
||||
}
|
||||
}
|
||||
if opt.VMLog != "" {
|
||||
if strings.HasPrefix(opt.VMLog, safePipePrefix) {
|
||||
if strings.HasPrefix(opt.VMLog, irunhcs.SafePipePrefix) {
|
||||
out = append(out, "--vm-log", opt.VMLog)
|
||||
} else {
|
||||
abs, err := filepath.Abs(opt.VMLog)
|
||||
|
||||
3
vendor/github.com/Microsoft/hcsshim/cmd/go-runhcs/runhcs_exec.go
generated
vendored
3
vendor/github.com/Microsoft/hcsshim/cmd/go-runhcs/runhcs_exec.go
generated
vendored
@@ -6,6 +6,7 @@ import (
|
||||
"path/filepath"
|
||||
"strings"
|
||||
|
||||
irunhcs "github.com/Microsoft/hcsshim/internal/runhcs"
|
||||
"github.com/containerd/go-runc"
|
||||
)
|
||||
|
||||
@@ -33,7 +34,7 @@ func (opt *ExecOpts) args() ([]string, error) {
|
||||
out = append(out, "--pid-file", abs)
|
||||
}
|
||||
if opt.ShimLog != "" {
|
||||
if strings.HasPrefix(opt.ShimLog, safePipePrefix) {
|
||||
if strings.HasPrefix(opt.ShimLog, irunhcs.SafePipePrefix) {
|
||||
out = append(out, "--shim-log", opt.ShimLog)
|
||||
} else {
|
||||
abs, err := filepath.Abs(opt.ShimLog)
|
||||
|
||||
Reference in New Issue
Block a user