mirror of
https://gitea.com/Lydanne/buildx.git
synced 2025-07-14 15:37:07 +08:00
vendor: update buildkit to 8effd45b
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
This commit is contained in:
5
vendor/github.com/Microsoft/hcsshim/internal/hcs/utils.go
generated
vendored
5
vendor/github.com/Microsoft/hcsshim/internal/hcs/utils.go
generated
vendored
@ -7,6 +7,7 @@ import (
|
||||
|
||||
"github.com/Microsoft/go-winio"
|
||||
diskutil "github.com/Microsoft/go-winio/vhd"
|
||||
"github.com/Microsoft/hcsshim/computestorage"
|
||||
"github.com/pkg/errors"
|
||||
"golang.org/x/sys/windows"
|
||||
)
|
||||
@ -36,7 +37,7 @@ func makeOpenFiles(hs []syscall.Handle) (_ []io.ReadWriteCloser, err error) {
|
||||
return fs, nil
|
||||
}
|
||||
|
||||
// creates a VHD formatted with NTFS of size `sizeGB` at the given `vhdPath`.
|
||||
// CreateNTFSVHD creates a VHD formatted with NTFS of size `sizeGB` at the given `vhdPath`.
|
||||
func CreateNTFSVHD(ctx context.Context, vhdPath string, sizeGB uint32) (err error) {
|
||||
if err := diskutil.CreateVhdx(vhdPath, sizeGB, 1); err != nil {
|
||||
return errors.Wrap(err, "failed to create VHD")
|
||||
@ -53,7 +54,7 @@ func CreateNTFSVHD(ctx context.Context, vhdPath string, sizeGB uint32) (err erro
|
||||
}
|
||||
}()
|
||||
|
||||
if err := hcsFormatWritableLayerVhd(uintptr(vhd)); err != nil {
|
||||
if err := computestorage.FormatWritableLayerVhd(ctx, windows.Handle(vhd)); err != nil {
|
||||
return errors.Wrap(err, "failed to format VHD")
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user