Skip to content
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

Demo app deploy failing on reconciliation #1939

Closed
1 task done
jfmatth opened this issue Oct 13, 2021 · 3 comments · Fixed by fluxcd/website#582
Closed
1 task done

Demo app deploy failing on reconciliation #1939

jfmatth opened this issue Oct 13, 2021 · 3 comments · Fixed by fluxcd/website#582

Comments

@jfmatth
Copy link

jfmatth commented Oct 13, 2021

Describe the bug

  • Deployed to MicroK8s per https://fluxcd.io/docs/guides/image-update
  • Installed Flux as instructed by above page to support automation components
  • After pulling down the podinfo-deployment.yaml, the reconcile fails

Steps to reproduce

flux bootstrap github \
  --components-extra=image-reflector-controller,image-automation-controller \
  --owner=$GITHUB_USER \
  --repository=flux-image-updates \
  --branch=main \
  --path=clusters/my-cluster \
  --read-write-key \
  --personal
 jfmatth@IICL00149  ~/development/flux-image-updates   main  flux reconcile kustomization flux-system --with-source

► annotating GitRepository flux-system in flux-system namespace
✔ GitRepository annotated
◎ waiting for GitRepository reconciliation
✔ fetched revision main/6fd69b58750084d37e87a02f7c58e7f65c946610
► annotating Kustomization flux-system in flux-system namespace
✔ Kustomization annotated
◎ waiting for Kustomization reconciliation
✗ Kustomization reconciliation failed: Deployment/podinfo namespace not specified, error: the server could not find the requested resource

Expected behavior

I would think it would deploy the podinfo app into my cluster

Screenshots and recordings

No response

OS / Distro

WSL2 attaching to MicroK8s on Ubuntu via kubectl

Flux version

flux: v0.18.3

Flux check

 jfmatth@IICL00149  ~/development/flux-image-updates   main  flux check
► checking prerequisites
✔ Kubernetes 1.21.5-3+83e2bb7ee39726 >=1.19.0-0
► checking controllers
✔ helm-controller: deployment ready
► ghcr.io/fluxcd/helm-controller:v0.12.0
✔ image-automation-controller: deployment ready
► ghcr.io/fluxcd/image-automation-controller:v0.15.0
✔ image-reflector-controller: deployment ready
► ghcr.io/fluxcd/image-reflector-controller:v0.12.0
✔ kustomize-controller: deployment ready
► ghcr.io/fluxcd/kustomize-controller:v0.15.5
✔ notification-controller: deployment ready
► ghcr.io/fluxcd/notification-controller:v0.17.1
✔ source-controller: deployment ready
► ghcr.io/fluxcd/source-controller:v0.16.0
✔ all checks passed
 jfmatth@IICL00149  ~/development/flux-image-updates   main 

Git provider

n/a

Container Registry provider

n/a

Additional context

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@somtochiama
Copy link
Member

Hey @jfmatth , This is a breaking change from a new release of kustomize-controller fluxcd/kustomize-controller#426.
You can resolve this by adding a namespace to the podinfo-deployment.yaml file.
Thanks for pointing out, we will update the docs and examples to reflect this change

@jfmatth
Copy link
Author

jfmatth commented Oct 13, 2021 via email

@jfmatth
Copy link
Author

jfmatth commented Oct 13, 2021

Yea that did it :)

I added namespace to the metadata section and it worked as expected. Weird that it requires that, seems like a bad coupling, but oh well.

apiVersion: apps/v1
kind: Deployment
metadata:
  name: podinfo
  namespace: default
 ...

Created a PR against the Podinfo repo stefanprodan/podinfo#154

@jfmatth jfmatth closed this as completed Oct 13, 2021
@stefanprodan stefanprodan reopened this Oct 14, 2021
dchapman992000 added a commit to dchapman992000/k8-fcos-gitops that referenced this issue Apr 5, 2024
Found fluxcd/flux2#1939 which warrants adding the namespace.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants