Skip to content

Commit

Permalink
Update cloud-go. (#254)
Browse files Browse the repository at this point in the history
  • Loading branch information
Gerrit91 authored Aug 23, 2023
1 parent c4aabc6 commit 54d83fa
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 5 deletions.
20 changes: 18 additions & 2 deletions cmd/tenant.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,15 @@ func (c *config) tenantApply() error {
}
if t.Payload.Meta != nil {
params := tenant.NewUpdateTenantParams()
params.SetBody(&models.V1TenantUpdateRequest{Tenant: &tars[i]})
tar := &tars[i]
params.SetBody(&models.V1TenantUpdateRequest{
DefaultQuotas: tar.DefaultQuotas,
Description: tar.Description,
IamConfig: tar.IamConfig,
Meta: tar.Meta,
Name: tar.Name,
Quotas: tar.Quotas,
})
resp, err := c.cloud.Tenant.UpdateTenant(params, nil)
if err != nil {
return err
Expand Down Expand Up @@ -200,7 +208,15 @@ func (c *config) tenantEdit(args []string) error {
return fmt.Errorf("tenant update error more or less than one tenant given:%d", len(purs))
}
pup := tenant.NewUpdateTenantParams()
pup.Body = &models.V1TenantUpdateRequest{Tenant: &purs[0]}
pur := &purs[0]
pup.Body = &models.V1TenantUpdateRequest{
DefaultQuotas: pur.DefaultQuotas,
Description: pur.Description,
IamConfig: pur.IamConfig,
Meta: pur.Meta,
Name: pur.Name,
Quotas: pur.Quotas,
}
uresp, err := c.cloud.Tenant.UpdateTenant(pup, nil)
if err != nil {
return err
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ require (
github.com/dcorbe/termui-dpc v0.0.0-20211125210512-9d2673a82dd6
github.com/dustin/go-humanize v1.0.1
github.com/fatih/color v1.15.0
github.com/fi-ts/cloud-go v0.21.0
github.com/fi-ts/cloud-go v0.22.0
github.com/gardener/gardener v1.59.0
github.com/gardener/machine-controller-manager v0.49.3
github.com/go-openapi/strfmt v0.21.7
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -151,8 +151,8 @@ github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.m
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
github.com/fatih/color v1.15.0 h1:kOqh6YHBtK8aywxGerMG2Eq3H6Qgoqeo13Bk2Mv/nBs=
github.com/fatih/color v1.15.0/go.mod h1:0h5ZqXfHYED7Bhv2ZJamyIOUej9KtShiJESRwBDUSsw=
github.com/fi-ts/cloud-go v0.21.0 h1:AK+6BjJn+omTfY/Ul0aSQ31ro7h4uwhlsJT4UuetFNA=
github.com/fi-ts/cloud-go v0.21.0/go.mod h1:BYrXp1jTvfxYRiL0B+LE+6ZDp3GF110y9Sr2tuRJo5c=
github.com/fi-ts/cloud-go v0.22.0 h1:ld8EhZ97+coNaHgRlX7KisyhJY0GBjvXT7L0xzMvQpk=
github.com/fi-ts/cloud-go v0.22.0/go.mod h1:BYrXp1jTvfxYRiL0B+LE+6ZDp3GF110y9Sr2tuRJo5c=
github.com/frankban/quicktest v1.14.5 h1:dfYrrRyLtiqT9GyKXgdh+k4inNeTvmGbuSgZ3lx3GhA=
github.com/frankban/quicktest v1.14.5/go.mod h1:4ptaffx2x8+WTWXmUCuVU6aPUX1/Mz7zb5vbUoiM6w0=
github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY=
Expand Down

0 comments on commit 54d83fa

Please sign in to comment.