Skip to content

Commit

Permalink
[cherry-pick] Update Kubernetes v1.18.9 dependencies (#474) (#479)
Browse files Browse the repository at this point in the history
/cherry-pick

Signed-off-by: 1gtm <1gtm@appscode.com>
  • Loading branch information
1gtm authored Dec 8, 2020
1 parent 6bb25a6 commit 5376405
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ require (
k8s.io/apimachinery v0.18.9
k8s.io/client-go v0.18.9
k8s.io/kube-openapi v0.0.0-20200410145947-61e04a5be9a6
kmodules.xyz/client-go v0.0.0-20201105071625-0b277310b9b8
kmodules.xyz/client-go v0.0.0-20201208053851-a1d7be95e006
kmodules.xyz/crd-schema-fuzz v0.0.0-20200922204806-c1426cd7fcf4
kmodules.xyz/custom-resources v0.0.0-20201124062543-bd8d35c21b0c
kmodules.xyz/offshoot-api v0.0.0-20201105074700-8675f5f686f2
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -949,6 +949,8 @@ k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89 h1:d4vVOjXm687F1iLSP2q3lyPPuyvTU
k8s.io/utils v0.0.0-20200324210504-a9aa75ae1b89/go.mod h1:sZAwmy6armz5eXlNoLmJcl4F1QuKu7sr+mFQ0byX7Ew=
kmodules.xyz/client-go v0.0.0-20201105071625-0b277310b9b8 h1:zs2+yI/Ola5HjdtfP29XD76Bx5BO4WchC2uN9lkhxQM=
kmodules.xyz/client-go v0.0.0-20201105071625-0b277310b9b8/go.mod h1:WXDwZBmvrcLgGcuO9iZpI9jcfPuDFfWbxA4EnhAFtGw=
kmodules.xyz/client-go v0.0.0-20201208053851-a1d7be95e006 h1:gNrNTwi0jViRqdszsb0W5CQF+ANNVFlvh/LO0A3R7dM=
kmodules.xyz/client-go v0.0.0-20201208053851-a1d7be95e006/go.mod h1:WXDwZBmvrcLgGcuO9iZpI9jcfPuDFfWbxA4EnhAFtGw=
kmodules.xyz/constants v0.0.0-20200923054614-6b87dbbae4d6/go.mod h1:DbiFk1bJ1KEO94t1SlAn7tzc+Zz95rSXgyUKa2nzPmY=
kmodules.xyz/crd-schema-fuzz v0.0.0-20200922204806-c1426cd7fcf4 h1:NWWv+Qju8xzHZT9hIk1+BbgQtIytNOoCU4g4vqUmh3M=
kmodules.xyz/crd-schema-fuzz v0.0.0-20200922204806-c1426cd7fcf4/go.mod h1:WrO3fryNyFCgqqyWnwI89lnzWA7kN072Ehya7ELGfzE=
Expand Down
8 changes: 7 additions & 1 deletion vendor/kmodules.xyz/client-go/core/v1/kubernetes.go
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,16 @@ func EnsureContainerDeleted(containers []core.Container, name string) []core.Con
func UpsertContainer(containers []core.Container, upsert core.Container) []core.Container {
for i, container := range containers {
if container.Name == upsert.Name {
err := mergo.MergeWithOverwrite(&container, upsert)
err := mergo.Merge(&container, upsert, mergo.WithOverride)
if err != nil {
panic(err)
}
// mergo does not overwrite "dst (container)" using empty "src (upsert)" values.
// This causes problem we want to remove args or commands (eg, disable TLS).
// TODO: should this be done for all the []string type fields (eg, EnvFrom etc.)?
container.Command = upsert.Command
container.Args = upsert.Args
container.Env = upsert.Env
containers[i] = container
return containers
}
Expand Down
2 changes: 1 addition & 1 deletion vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -844,7 +844,7 @@ k8s.io/utils/net
k8s.io/utils/path
k8s.io/utils/pointer
k8s.io/utils/trace
# kmodules.xyz/client-go v0.0.0-20201105071625-0b277310b9b8
# kmodules.xyz/client-go v0.0.0-20201208053851-a1d7be95e006
kmodules.xyz/client-go
kmodules.xyz/client-go/api/v1
kmodules.xyz/client-go/apiextensions
Expand Down

0 comments on commit 5376405

Please sign in to comment.