The following sections explain how to resolve common issues you may encounter when using decK with Konnect.
If you have verified that your token is correct but decK can’t connect to your account, check for conflicts with the decK config file ($HOME/.deck.yaml
) and the Konnect token file.
A decK config file is likely conflicting with the token file and passing another set of credentials.
To resolve, remove one of the duplicate sets of credentials.
When migrating from Kong Gateway to Konnect, make sure to remove any _workspace
tags. If you leave _workspace
in, you get the following error:
Error: checking if workspace exists
Remove the _workspace
key to resolve this error.
You can now sync the file as-is to apply it to the default Control Plane or add a key to apply the configuration to a specific Control Plane.
To apply the configuration to custom Control Planes, replace _workspace
with control_plane_name: ExampleName
.
For example, to export the configuration from workspace staging
to Control Plane staging
, you would change:
To:
_konnect:
control_plane_name: staging
decK can run against Kong Gateway or Konnect.
By default, it targets Kong Gateway, unless a setting tells decK to point to Konnect instead.
decK determines the environment using the following order of precedence:
-
If the declarative configuration file contains the _konnect
entry, decK runs
against Konnect.
-
If the --kong-addr
flag is set to a non-default value, decK runs against Kong Gateway.
-
If a Konnect token is set in any way (flag, file, or decK config), decK runs against Konnect.
-
If none of the above are present, decK runs against Kong Gateway.