Skip to content

aws-for-fluent-bit: add serviceAnnotations and daemonSetAnnotations - #1361

Open
ranyhb wants to merge 1 commit into
aws:masterfrom
ranyhb:fluent-bit-object-annotations
Open

aws-for-fluent-bit: add serviceAnnotations and daemonSetAnnotations#1361
ranyhb wants to merge 1 commit into
aws:masterfrom
ranyhb:fluent-bit-object-annotations

Conversation

@ranyhb

@ranyhb ranyhb commented Aug 19, 2026

Copy link
Copy Markdown

Issue

No open issue. Related: #1305 (podLabels) is the complementary change — see Scope below.

Description of changes

The chart can annotate the pods (annotations) and the ServiceAccount
(serviceAccount.annotations), but there is no way to annotate the two objects
themselves:

  • templates/service.yaml renders no metadata.annotations block at all.
  • templates/daemonset.yaml renders .Values.annotations at
    spec.template.metadata, i.e. on the pods — the DaemonSet object's own
    metadata takes only name/namespace/labels.

That blocks the ordinary uses of object annotations — IaC/controller hints,
prometheus.io/* on the Service, ArgoCD sync options, external-dns. In our case
a Pulumi deployment needs pulumi.com/skipAwait on both objects and has to
post-process the rendered manifests to get it.

This adds two values, following aws-load-balancer-controller in this repo,
which already ships exactly this pair:

key object
serviceAnnotations the monitoring Service
daemonSetAnnotations the DaemonSet itself (pods stay on annotations)

Both are top-level, matching aws-load-balancer-controller's
serviceAnnotations/deploymentAnnotations. Note service.annotations was not
an option: the top-level service: key is the Fluent Bit [SERVICE] config
stanza, not the Kubernetes Service.

For reference, the community fluent/helm-charts fluent-bit chart already
supports annotations and labels on both objects; this brings the AWS chart
closer to parity.

Scope

Deliberately does not touch podLabels — that is #1305, which I have not
duplicated. The two changes are independent and compose cleanly.

Checklist

  • Added/modified documentation as required (such as the README.md for modified charts)
  • Incremented the chart version in Chart.yaml for the modified chart(s)
  • Manually tested. Describe what testing was done in the testing section below
  • Make sure the title of the PR is a good description that can go into the release notes

Testing

helm template, chart version held equal so only the template change is compared:

values result
both keys unset (default) byte-identical to the unmodified chart — 188 lines, 6 documents
serviceAnnotations + daemonSetAnnotations set exactly two additions, 4 lines, the two metadata.annotations blocks
$ diff before.yaml after.yaml      # keys unset
$ diff after_unset.yaml after_set.yaml
111a112,113
>   annotations:
>     pulumi.com/skipAwait: "true"
129a132,133
>   annotations:
>     pulumi.com/skipAwait: "true"

helm lint passes. Existing users see no change: both keys default to {} and
each block is guarded with {{- with }}.

The chart can annotate the pods (annotations) and the ServiceAccount, but
neither the Service nor the DaemonSet object itself. service.yaml renders no
metadata.annotations block at all, and .Values.annotations is applied at
spec.template.metadata.

Adds two top-level values following aws-load-balancer-controller in this repo,
which already ships serviceAnnotations/deploymentAnnotations. Both default to
{} and are guarded with 'with', so rendering is unchanged for existing users.
@ranyhb
ranyhb force-pushed the fluent-bit-object-annotations branch from 1ca2a72 to 9e3eaed Compare August 19, 2026 07:34
@ranyhb

ranyhb commented Aug 20, 2026

Copy link
Copy Markdown
Author

@cdirubbio hi, can u take a look ?

@ranyhb

ranyhb commented Aug 20, 2026

Copy link
Copy Markdown
Author

@cdirubbio @wweiwei-li @shraddhabang — sorry for the direct ping. CODEOWNERS for this chart resolves to * @dims, who noted on #1305 that he's no longer at AWS, so stable/aws-for-fluent-bit/ has no active owner. You three are the most recently active maintainers here — could one of you review, or point me at the right owner?

TL;DR: aws-for-fluent-bit can annotate the pods and the ServiceAccount, but not the Service or the DaemonSet object — service.yaml renders no annotations block at all, and .Values.annotations lands on the pod template. Adds serviceAnnotations + daemonSetAnnotations, copying the serviceAnnotations/deploymentAnnotations pair aws-load-balancer-controller already ships in this repo. Both default to {}; render is byte-identical when unset. README + Chart.yaml bump included.

@ranyhb

ranyhb commented Aug 25, 2026

Copy link
Copy Markdown
Author

@viveksb007 can u take a look ? small pr

@ranyhb

ranyhb commented Aug 27, 2026

Copy link
Copy Markdown
Author

@cdirubbio @shraddhabang @jaydeokar — mind taking a look? Small PR (+18/-1).

Adds serviceAnnotations + daemonSetAnnotations to aws-for-fluent-bit, mirroring the pair aws-load-balancer-controller already ships in this repo. Both default to {}, so the render is byte-identical when unset. Chart is still without an owner (CODEOWNERS points at @dims, who left AWS) — happy to be redirected if someone else should look.

@ranyhb

ranyhb commented Sep 3, 2026

Copy link
Copy Markdown
Author

@cdirubbio hi, can you take a look? Small PR (+18/-1).

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 this pull request may close these issues.

1 participant