-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Closed
Labels
kind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.triage/acceptedIndicates an issue or PR is ready to be actively worked on.Indicates an issue or PR is ready to be actively worked on.
Description
What broke? What's expected?
On Ubuntu, when specifying an external plugin to any subcommand (e.g. init
) through the --plugins
flag, the subcommand fails if XDG_CONFIG_HOME
is set to its default value $HOME/.config
, with the following error:
2023/02/11 15:35:25 no plugin could be resolved with key "myexternalplugin/v1"
The subcommands eventually run successfully after unsetting XDG_CONFIG_HOME
.
Reproducing this issue
- Set XDG_CONFIG_HOME variable in the shell:
export XDG_CONFIG_HOME=$HOME/.config
- Create a folder for an external plugin:
mkdir -p $XDG_CONFIG_HOME/kubebuilder/plugins/myexternalplugin/v1
- Copy the plugin binary to the directory created in 2).
- Initialize a new project:
kubebuilder init --plugins=myexternalplugin/v1
- Notice how the execution will exit with an error, and
myexternalplugin
won't appear in the available plugins table.
KubeBuilder (CLI) Version
3.9.0
PROJECT version
No response
Plugin versions
No response
Other versions
Go version: 1.19.4 linux/amd64
OS version: Ubuntu 22.04.1 LTS
Extra Labels
No response
Metadata
Metadata
Assignees
Labels
kind/bugCategorizes issue or PR as related to a bug.Categorizes issue or PR as related to a bug.triage/acceptedIndicates an issue or PR is ready to be actively worked on.Indicates an issue or PR is ready to be actively worked on.