-
Notifications
You must be signed in to change notification settings - Fork 435
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
Adding Additional Containers to the Collector spec #1980
Changes from all commits
28456d5
5461b23
476308b
f1c7b4f
8de5619
a19f9a5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix' | ||
change_type: enhancement | ||
|
||
# The name of the component, or a single word describing the area of concern, (e.g. operator, target allocator, github action) | ||
component: operator | ||
|
||
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`). | ||
note: Add `AdditionalContainers` to the collector spec allowing to configure sidecar containers. This only applies to Deployment/StatefulSet/DeamonSet deployment modes of the collector. | ||
|
||
# One or more tracking issues related to the change | ||
issues: [1987] | ||
|
||
# (Optional) One or more lines of additional information to render under the primary note. | ||
# These lines will be padded with 2 spaces and then inserted directly into the document. | ||
# Use pipe (|) for multiline entries. | ||
subtext: |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -213,6 +213,22 @@ type OpenTelemetryCollectorSpec struct { | |
// +optional | ||
InitContainers []v1.Container `json:"initContainers,omitempty"` | ||
|
||
// AdditionalContainers allows injecting additional containers into the Collector's pod definition. | ||
// These sidecar containers can be used for authentication proxies, log shipping sidecars, agents for shipping | ||
// metrics to their cloud, or in general sidecars that do not support automatic injection. This option only | ||
// applies to Deployment, DaemonSet, and StatefulSet deployment modes of the collector. It does not apply to the sidecar | ||
// deployment mode. More info about sidecars: | ||
// https://kubernetes.io/docs/tasks/configure-pod-container/share-process-namespace/ | ||
// | ||
// Container names managed by the operator: | ||
// * `otc-container` | ||
// | ||
// Overriding containers managed by the operator is outside the scope of what the maintainers will support and by | ||
// doing so, you wil accept the risk of it breaking things. | ||
// | ||
// +optional | ||
AdditionalContainers []v1.Container `json:"additionalContainers,omitempty"` | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If we proceed with this PR we should clarify how this is supported e.g. https://github.com/prometheus-operator/prometheus-operator/blob/main/pkg/apis/monitoring/v1/prometheus_types.go#L337 We also should clarify if it is supported for all deployment modes (e.g. deployment, sidecar...) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I updated the godoc comment, I added in an explanation, link to additional information about sidecars, and I added a warning about overriding the container that the operator generates. Let me know if this is good enough or if I need to improve it more. |
||
|
||
// ObservabilitySpec defines how telemetry data gets handled. | ||
// | ||
// +optional | ||
|
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Large diffs are not rendered by default.
Large diffs are not rendered by default.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,8 @@ | ||
resources: | ||
- manager.yaml | ||
apiVersion: kustomize.config.k8s.io/v1beta1 | ||
kind: Kustomization | ||
images: | ||
- name: controller | ||
newName: ghcr.io/matt/opentelemetry-operator/opentelemetry-operator | ||
newTag: 0.82.0-9-g6f4246c |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why there is this link?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I though it would be helpful to link to more information about sidecars. I can remove it if we don't feel its useful.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's worth keeping, I appreciate doclinks