Deployment was successful, even though pod couldn't be updated

Hi everyone!

I tested a deployment to our k8s cluster. After the initial pod creation went well, I did an update to the pod configuration (changed the image source), created a new release and did another deploy. Unfortunately, I now had a typo in my YAML file for the new image location, so the image couldn’t be pulled, with the pod update hanging on this step (the usual switching between ErrImagePull and ImagePullBackOff).

However, on the Octopus side of things I got the message that my deployment was successful.

I am new to all things Octopus, but I didn’t expect this behaviour (since the pod couldn’t be updated I would expect some sort of fail), so I wonder if I did something wrong or did some wrong thinking? I did this using the “raw Kubernetes YAML” step.

Thanks in advance,
Anita

Hi Anita,

Welcome to the Octopus help site.

That does sound a little odd. I would expect if an error is returned in your “raw Kubernetes YAML” step, then the deployment would stop.

I have directly messaged you a link on your user. Could you please upload your deployment task raw log to this link to investigate this further for you?

Hopefully, we can get to the bottom of this quickly for you.

Kind Regards,
Sean

Hi Sean,

thanks for your quick reply.

I just tried it again (added the same typo, a dot at the end of the image tag) with the same outcome. I uploaded the logfile as requested.

Thanks again and kind regards,
Anita

Hi Anita,

Thank you very much for that.

I will look through this and get back to you as quickly as possible!

Kind Regards,
Sean

1 Like

Hi Anita,

After looking at your logs and thinking about your issue, could you please upload your YAML file to that same link I sent you?

We were hoping to test it on our side to recreate your issue and potentially test a fix.

Also, do you happen to have a readiness probe inside of your YAML? We include this in our “Deploy Kubernetes Containers” step as an option. However, we do not add the readiness probe to the “Raw Kubernetes YAML” step. This would make sure that the pod is active and working correctly.

We are looking forward to hearing from you!

Kind Regards,
Sean

Hi Sean,

oops, yeah, I think the readiness probe might actually be the issue, because no, I didn’t add one to my YAML file.

That’s where the “all new to Octopus” comes into play :wink: , and I will check out the “Deploy Kubernetes Containers” step in comparison to the “Raw Kubernetes YAML” step, and now know I need to add a readiness probe if I use the later.

This already helped me a lot and I’m pretty sure will also solve my issue.

Thanks for your time and help,
kind regards,
Anita

1 Like

Hi Anita,

No problem at all; we’re always happy to help! Should you wish to read more into the “Deploy Kubernetes Containers” step, we have a documentation page that will hopefully help further.

If you need anything else on this or any topic in the future, please contact us again!

Kind Regards,
Sean

1 Like

Hi Anita,

Just a quick follow up, it may be helpful to use the “Reference a Package” option in the raw YAML step if you continue using this step in the future. This will allow you to choose a package feed, the ID of the package, and give it a name that you can reference in your YAML directly, instead of putting in the image name each time into your script.

We have a page for it that should help guide you through it if you wish to do this, and if you need any assistance, you can always contact us about it.

Kind Regards,
Sean

1 Like

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.