-
Notifications
You must be signed in to change notification settings - Fork 80
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
[Bug]: Wrong deployment image processing #346
Comments
Btw, what is going on here: k8sgpt-operator/controllers/k8sgpt_controller.go Lines 175 to 179 in db04fbd
If image repo is not the same as in Maybe it should update image repo to |
yes that looks wrong 👍 |
Checklist
Affected Components
K8sGPT Version
v0.3.8
Kubernetes Version
v1.28.0
Host OS and its Version
No response
Steps to reproduce
Include port in repository in
K8sGPT
object like<host>:<port>/<path>/<image>
.Expected behaviour
Operator will create a deployment with normal image.
Actual behaviour
Operator will turn image in
<host>:<tag>
, thus result intoImagePullBackOff
.Additional Information
I've found the lines were this happens:
k8sgpt-operator/controllers/k8sgpt_controller.go
Lines 168 to 180 in db04fbd
Quick solution is to parse image like this:
or
Possible better solution is to use maybe
net/url
or some other lib.Test: https://go.dev/play/p/nIFGk2QroT5
The text was updated successfully, but these errors were encountered: