Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(deps): bump github.com/kong/deck from 1.20.0 to 1.21.0 #691

Merged
merged 1 commit into from
Jun 1, 2023

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github May 31, 2023

Bumps github.com/kong/deck from 1.20.0 to 1.21.0.

Release notes

Sourced from github.com/kong/deck's releases.

v1.21.0

See the changelog.

Changelog

Sourced from github.com/kong/deck's changelog.

[v1.21.0]

Release date: 2023/05/31

Add

  • Add support for updating Services, Routes, and Consumers by changing their IDs, but retaining their names. #918

Fix

  • Return proper error when HTTP calls fail on validate. #869
  • Replace old docs link in convert and fix its docstring. #905

Misc

  • Bump Go toolchain to 1.20. #898
Commits
  • 735fbe2 chore: fix golang version pinning
  • 9294104 chore: pin goreleaser to v1.16.2
  • d794d39 docs: prepare changelog for v1.21.0 release
  • 240d962 chore: enable golang-ci errorlint (#923)
  • b5d2c99 feat: allow updating IDs of Services, Routes and Consumers while keeping thei...
  • f60e1b9 chore(deps): bump k8s.io/code-generator from 0.27.1 to 0.27.2
  • cc429cf chore(deps): bump github.com/imdario/mergo from 0.3.15 to 0.3.16
  • 065bb41 chore(deps): bump github.com/stretchr/testify from 1.8.2 to 1.8.3
  • bc3e247 tests: run all >=3.0 tests against Konnect (#919)
  • bb3ef61 chore(deps): bump github.com/kong/go-kong from 0.41.0 to 0.42.0
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot dependabot bot requested review from a team and shaneutt as code owners May 31, 2023 15:58
@dependabot dependabot bot added dependencies Pull requests that update a dependency file go Pull requests that update Go code labels May 31, 2023
@dependabot dependabot bot temporarily deployed to gcloud May 31, 2023 15:58 Inactive
Bumps [github.com/kong/deck](https://github.com/kong/deck) from 1.20.0 to 1.21.0.
- [Release notes](https://github.com/kong/deck/releases)
- [Changelog](https://github.com/Kong/deck/blob/main/CHANGELOG.md)
- [Commits](Kong/deck@v1.20.0...v1.21.0)

---
updated-dependencies:
- dependency-name: github.com/kong/deck
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot force-pushed the dependabot/go_modules/github.com/kong/deck-1.21.0 branch from 1b1da3e to d281d3f Compare June 1, 2023 09:02
@dependabot dependabot bot temporarily deployed to gcloud June 1, 2023 09:02 Inactive
@codecov-commenter
Copy link

codecov-commenter commented Jun 1, 2023

Codecov Report

Patch coverage has no change and project coverage change: +0.11 🎉

Comparison is base (f54fbe8) 59.70% compared to head (d281d3f) 59.81%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #691      +/-   ##
==========================================
+ Coverage   59.70%   59.81%   +0.11%     
==========================================
  Files          43       43              
  Lines        3474     3474              
==========================================
+ Hits         2074     2078       +4     
+ Misses       1131     1127       -4     
  Partials      269      269              
Flag Coverage Δ
integration-test 59.81% <ø> (+0.11%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

see 1 file with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@pmalek
Copy link
Member

pmalek commented Jun 1, 2023

The only place where deck is being used is in the bump diagnostics functionality:

case PostgreSQL:
out, err := os.CreateTemp(os.TempDir(), "ktf-kong-")
if err != nil {
return diagnostics, fmt.Errorf("could not create temp file: %w", err)
}
defer os.Remove(out.Name())
dumpConfig := dump.Config{}
addr, err := a.ProxyAdminURL(ctx, cluster)
if err != nil {
return diagnostics, fmt.Errorf("could not build Kong client: %w", err)
}
opts := deckutils.KongClientConfig{
Address: addr.String(),
HTTPClient: &http.Client{
Timeout: time.Second * 90, //nolint:gomnd
},
TLSSkipVerify: true,
}
if a.proxyEnterpriseSuperAdminPassword != "" {
opts.Headers = append(opts.Headers, "kong-admin-token:"+a.proxyEnterpriseSuperAdminPassword)
}
client, err := deckutils.GetKongClient(opts)
if err != nil {
return diagnostics, fmt.Errorf("could not build Kong client: %w", err)
}
workspaces, err := client.Workspaces.ListAll(ctx)
var kongAPIError *kong.APIError
if errors.As(err, &kongAPIError) && kongAPIError.Code() == http.StatusNotFound {
defaultws := kong.Workspace{Name: kong.String("default")}
workspaces = []*kong.Workspace{&defaultws}
} else if err != nil {
return diagnostics, fmt.Errorf("could get workspaces: %w", err)
}
for _, workspace := range workspaces {
wsOpts := opts
wsOpts.Workspace = *workspace.Name
var wsClient *kong.Client
if *workspace.Name == "default" {
// arguably a workspaced client for default should work on OSS, but it doesn't!
wsClient = client
} else {
wsClient, err = deckutils.GetKongClient(wsOpts)
if err != nil {
return diagnostics, fmt.Errorf("could not build Kong client: %w", err)
}
}
// deck will forcibly append the extension if you omit it
out, err := os.CreateTemp(os.TempDir(), "ktf-kong-config-*.yaml")
if err != nil {
return diagnostics, fmt.Errorf("could not create temp file: %w", err)
}
defer os.Remove(out.Name())
rawState, err := dump.Get(ctx, wsClient, dumpConfig)
if err != nil {
return diagnostics, fmt.Errorf("could not retrieve config from Kong: %w", err)
}
currentState, err := state.Get(rawState)
if err != nil {
return diagnostics, fmt.Errorf("could not build Kong state: %w", err)
}
err = file.KongStateToFile(currentState, file.WriteConfig{
Filename: out.Name(),
FileFormat: file.YAML,
KongVersion: kongVersion.Version,
})
if err != nil {
return diagnostics, fmt.Errorf("could not write Kong config: %w", err)
}
config, err := os.ReadFile(out.Name())
if err != nil {
return diagnostics, fmt.Errorf("could not read Kong config: %w", err)
}
diagnostics[*workspace.Name+"_pg_config.yaml"] = config
}

@czeslavo Do I understand it correctly that the changes in 1.21 do not impact that and we can merge this?

@czeslavo
Copy link
Contributor

czeslavo commented Jun 1, 2023

In general, v1.21.0 does not introduce any breaking changes, so we're fine to merge it. In KIC we held bumping on just to make sure that the missing E2E test is in place to prove that the bump fixes the regression described in Kong/kubernetes-ingress-controller#4025.

@czeslavo czeslavo merged commit 2e6f619 into main Jun 1, 2023
32 checks passed
@czeslavo czeslavo deleted the dependabot/go_modules/github.com/kong/deck-1.21.0 branch June 1, 2023 11:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file go Pull requests that update Go code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants