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

Nginx autoinstrument fails for nginx-ingress pod #2366

Closed
djluck opened this issue Nov 17, 2023 · 2 comments · Fixed by #2385
Closed

Nginx autoinstrument fails for nginx-ingress pod #2366

djluck opened this issue Nov 17, 2023 · 2 comments · Fixed by #2385
Assignees
Labels
area:auto-instrumentation Issues for auto-instrumentation auto-instrumentation:nginx bug Something isn't working

Comments

@djluck
Copy link

djluck commented Nov 17, 2023

Component(s)

instrumentation

What happened?

Description

When using nginx auto-instrumentation with nginx, pods fail to create with this error:

conditions:
  - lastTransitionTime: "2023-11-16T19:59:24Z"
    message: 'Pod "ingress-nginx-internal-controller-5f98f56d9d-w8k4k" is invalid:
      spec.initContainers[0].lifecycle: Forbidden: may not be set for init containers'
    reason: FailedCreate
    status: "True"
    type: ReplicaFailure

Seems this issue may be related to another issue previously reported: #1820

Steps to Reproduce

  • opentelemetry-operator helm chart 0.41.0
  • Add instrumentation.opentelemetry.io/inject-nginx: monitoring/demo-nginx-instrumentation to the nginx ingress helm chart

Expected Result

Auto-instrumentation works

Actual Result

Fails with above error.

Kubernetes Version

1.26.3

Operator version

0.41.0

Collector version

NA

Environment information

Environment

OS: (e.g., "Ubuntu 20.04")
Compiler(if manually compiled): (e.g., "go 14.2")

Log output

No response

Additional context

No response

@djluck djluck added bug Something isn't working needs triage labels Nov 17, 2023
@TylerHelmuth
Copy link
Member

/cc @chrlic

@chrlic
Copy link
Member

chrlic commented Nov 20, 2023

I'm on it

chrlic added a commit to chrlic/opentelemetry-operator that referenced this issue Nov 22, 2023
chrlic added a commit to chrlic/opentelemetry-operator that referenced this issue Nov 22, 2023
@chrlic chrlic mentioned this issue Nov 22, 2023
pavolloffay pushed a commit that referenced this issue Nov 27, 2023
* fix for #2366

* added cloggen

* typo

* typo

* e2e test for lifecycle removal from init container

* e2e test for lifecycle removal in init container
ItielOlenick pushed a commit to ItielOlenick/opentelemetry-operator that referenced this issue May 1, 2024
* fix for open-telemetry#2366

* added cloggen

* typo

* typo

* e2e test for lifecycle removal from init container

* e2e test for lifecycle removal in init container
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:auto-instrumentation Issues for auto-instrumentation auto-instrumentation:nginx bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants