devspace
devspace copied to clipboard
devspace hook event: ["devCommand:after:deploy"] stopped working after upg to v6
What happened? I've upgraded devspace from v5 to v6 and hook event: ["devCommand:after:deploy"] stopped working (do not trigger)
What did you expect to happen instead? That hooks are still working similar to the v5 devspace version as defined in the yaml file.
How can we reproduce the bug? (as minimally and precisely as possible)
- Prepare devspace.yaml with deployments
- Add hook event: ["devCommand:after:deploy"]
- Run: devspace dev
My devspace.yaml:
version: v1beta11
...
deployments:
- name: app-kalendarium-ui
helm:
componentChart: true
...
...
hooks:
- command: "kubectl"
args: ["port-forward", "pod/mongo-mongodb-replicaset-0", "27018:27017"]
background: true
events: ["devCommand:after:deploy"]
Local Environment:
- DevSpace Version: 6.0.1
- Operating System: windows
- ARCH of the OS: AMD64 Kubernetes Cluster:
- Cloud Provider: rancher-desktop
- Kubernetes Version: Client Version: version.Info{Major:"1", Minor:"22", GitVersion:"v1.22.4", GitCommit:"b695d79d4f967c403a96986f1750a35eb75e75f1", GitTreeState:"clean", BuildDate:"2021-11-17T15:48:33Z", GoVersion:"go1.16.10", Compiler:"gc", Platform:"windows/amd64"} Server Version: version.Info{Major:"1", Minor:"22", GitVersion:"v1.22.8+k3s1", GitCommit:"21fed356e6a180b0477702b170ae31968a084b40", GitTreeState:"clean", BuildDate:"2022-03-31T01:57:00Z", GoVersion:"go1.16.10", Compiler:"gc", Platform:"linux/amd64"}
Anything else we need to know? Was working in v5 version
/kind bug
@slazak thanks for creating this issue! The hook was removed in v6, and we recommend to use the after:deploy
event instead. Would that work for you?
I use "devCommand:before:execute" and it works as well in my case. It would be good to update v6 docs with the hooks that were removed. Thanks