aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2022-03-09 12:50:01 -0500
committerGitHub <noreply@github.com>2022-03-09 12:50:01 -0500
commitf960ac7ec3e226a38bed7cf6a6f9e8775b13b7f1 (patch)
treebc70fd659f07be3d85092bf5e44e8ba0698a7b31
parent418ab2e5e154cb0df13f2e901cf4aea31a5cd0a9 (diff)
parent8f2f8d4cadf95dea67d2cfc4a0c96c57234c0728 (diff)
downloadpodman-f960ac7ec3e226a38bed7cf6a6f9e8775b13b7f1.tar.gz
podman-f960ac7ec3e226a38bed7cf6a6f9e8775b13b7f1.tar.bz2
podman-f960ac7ec3e226a38bed7cf6a6f9e8775b13b7f1.zip
Merge pull request #13470 from Luap99/yamlv2
use gopkg.in/yaml.v2 instead of v3
-rw-r--r--go.mod2
-rw-r--r--pkg/domain/infra/abi/play.go6
-rw-r--r--vendor/modules.txt2
3 files changed, 5 insertions, 5 deletions
diff --git a/go.mod b/go.mod
index f81a604be..b61491cc0 100644
--- a/go.mod
+++ b/go.mod
@@ -69,7 +69,7 @@ require (
golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27
golang.org/x/text v0.3.7
google.golang.org/protobuf v1.27.1
- gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b
+ gopkg.in/yaml.v2 v2.4.0
k8s.io/api v0.22.5
k8s.io/apimachinery v0.22.5
)
diff --git a/pkg/domain/infra/abi/play.go b/pkg/domain/infra/abi/play.go
index 4d8112c47..e72584207 100644
--- a/pkg/domain/infra/abi/play.go
+++ b/pkg/domain/infra/abi/play.go
@@ -28,7 +28,7 @@ import (
"github.com/ghodss/yaml"
"github.com/pkg/errors"
"github.com/sirupsen/logrus"
- yamlv3 "gopkg.in/yaml.v3"
+ yamlv2 "gopkg.in/yaml.v2"
v1apps "k8s.io/api/apps/v1"
v1 "k8s.io/api/core/v1"
)
@@ -655,7 +655,7 @@ func readConfigMapFromFile(r io.Reader) (v1.ConfigMap, error) {
func splitMultiDocYAML(yamlContent []byte) ([][]byte, error) {
var documentList [][]byte
- d := yamlv3.NewDecoder(bytes.NewReader(yamlContent))
+ d := yamlv2.NewDecoder(bytes.NewReader(yamlContent))
for {
var o interface{}
// read individual document
@@ -669,7 +669,7 @@ func splitMultiDocYAML(yamlContent []byte) ([][]byte, error) {
if o != nil {
// back to bytes
- document, err := yamlv3.Marshal(o)
+ document, err := yamlv2.Marshal(o)
if err != nil {
return nil, errors.Wrapf(err, "individual doc yaml could not be marshalled")
}
diff --git a/vendor/modules.txt b/vendor/modules.txt
index 8214e0b98..a797d4556 100644
--- a/vendor/modules.txt
+++ b/vendor/modules.txt
@@ -881,9 +881,9 @@ gopkg.in/square/go-jose.v2/json
# gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7
gopkg.in/tomb.v1
# gopkg.in/yaml.v2 v2.4.0
+## explicit
gopkg.in/yaml.v2
# gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b
-## explicit
gopkg.in/yaml.v3
# k8s.io/api v0.22.5
## explicit