Update module github.com/containers/storage to v1.47.0

Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
This commit is contained in:
renovate[bot]
2023-06-27 00:12:20 +00:00
committed by GitHub
parent 32da299965
commit d72d53cc51
124 changed files with 3194 additions and 1358 deletions

View File

@@ -37,13 +37,16 @@ func (c *command) Run(arg ...string) ([][]string, error) {
cmd.Stderr = &stderr
id := uuid.New().String()
joinedArgs := strings.Join(cmd.Args, " ")
joinedArgs := cmd.Path
if len(cmd.Args) > 1 {
joinedArgs = strings.Join(append([]string{cmd.Path}, cmd.Args[1:]...), " ")
}
logger.Log([]string{"ID:" + id, "START", joinedArgs})
if err := cmd.Run(); err != nil {
return nil, &Error{
Err: err,
Debug: strings.Join([]string{cmd.Path, joinedArgs[1:]}, " "),
Debug: joinedArgs,
Stderr: stderr.String(),
}
}
@@ -61,7 +64,7 @@ func (c *command) Run(arg ...string) ([][]string, error) {
output := make([][]string, len(lines))
for i, l := range lines {
output[i] = strings.Fields(l)
output[i] = strings.Split(l, "\t")
}
return output, nil

View File

@@ -15,5 +15,5 @@ var (
zpoolPropList = []string{"name", "health", "allocated", "size", "free", "readonly", "dedupratio", "fragmentation", "freeing", "leaked"}
zpoolPropListOptions = strings.Join(zpoolPropList, ",")
zpoolArgs = []string{"get", "-p", zpoolPropListOptions}
zpoolArgs = []string{"get", "-Hp", zpoolPropListOptions}
)

View File

@@ -15,5 +15,5 @@ var (
zpoolPropList = []string{"name", "health", "allocated", "size", "free", "readonly", "dedupratio"}
zpoolPropListOptions = strings.Join(zpoolPropList, ",")
zpoolArgs = []string{"get", "-p", zpoolPropListOptions}
zpoolArgs = []string{"get", "-Hp", zpoolPropListOptions}
)

View File

@@ -49,9 +49,6 @@ func GetZpool(name string) (*Zpool, error) {
return nil, err
}
// there is no -H
out = out[1:]
z := &Zpool{Name: name}
for _, line := range out {
if err := z.parseLine(line); err != nil {