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

[Feature]: Use Recommended Labels in K8s generator #122

Open
2 tasks done
svrnm opened this issue Jan 13, 2025 · 0 comments · May be fixed by #124
Open
2 tasks done

[Feature]: Use Recommended Labels in K8s generator #122

svrnm opened this issue Jan 13, 2025 · 0 comments · May be fixed by #124
Labels
component/generator Related to a generator component enhancement New feature or request

Comments

@svrnm
Copy link
Member

svrnm commented Jan 13, 2025

Problem Statement

The generated k8s manfiests use labels like service and app, they seem to be commonly used, but not official. Also the current setup creates a view in cilium hubble like this:

Screenshot 2025-01-13 at 10 06 14

Proposed Solution

K8s has a set of "recommended labels" which are also supported by a variety of tools (e.g. cilium), we should use them instead of app or service.

The recommended labels are listed here: https://kubernetes.io/docs/concepts/overview/working-with-objects/common-labels/

So we could do something like the following defaults

metadata:
  labels:
    app.kubernetes.io/name: <name of the service, database, loader>
    app.kubernetes.io/instance: <name of the service, database, loader>-<randomly generated id>
    app.kubernetes.io/version: <version of the used image>
    app.kubernetes.io/component: <service or database or loader>
    app.kubernetes.io/part-of: <default to ApplicationSimulator>

Additionally we allow them to be overwritten by the user.

Alternatives Considered

No response

Additional Context

No response

Checklist

@svrnm svrnm added enhancement New feature or request triage This issue or pull request requires triaging component/generator Related to a generator component and removed triage This issue or pull request requires triaging labels Jan 13, 2025
@svrnm svrnm linked a pull request Jan 15, 2025 that will close this issue
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/generator Related to a generator component enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant