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

K8s CRD Plugin #58

Open
timsanwald opened this issue Nov 13, 2024 · 5 comments
Open

K8s CRD Plugin #58

timsanwald opened this issue Nov 13, 2024 · 5 comments

Comments

@timsanwald
Copy link

timsanwald commented Nov 13, 2024

Describe the solution you'd like
Provide a plugin to track generic costs via CRD in opencost. This could be useful for tracking multiple cost scenarios e.g. Operating Costs ($100 per month per namespace), non-supported external assets (e.g. databases from third party).

Describe alternatives you've considered
Other options would be to provide plugins for each and every system, or dummy values in cloud cost specifications. None is really valueable.

Additional context

Simple example, values are not thought through, might be worth to look at some other specifications.

apiVersion: io.opencost/v1
kind: Cost
metadata:
  name: namespace-operations
  namespace: blueprint
spec:
  cost: 100
  currency: "$"
  recurring: "Monthly"
@ameijer
Copy link
Contributor

ameijer commented Nov 13, 2024

interesting idea! I like it

@dwbrown2
Copy link

Have heard lots of requests for this across the community! Would be really interesting to find a solution... is plugin def the right approach?

@dwbrown2
Copy link

@timsanwald @jggoebel both of you guys recently made this really cool proposal! excited to explore different paths here..

opencost/opencost#2991

@jggoebel
Copy link

Thank you @dwbrown2 for linking this!
What a coincidence that two people came up with a similar idea.

I think that the approach i proposed by adding labels to existing CRDs might be even better, that way the cost is directly linked to the CRD producing the cost. Otherwise for every CRD that produces cost we would have to create a Cost resource. However for some ressources managed outside the cluster there might be no CRD (Like the mentioned external database).
Maybe a combined approach would be sufficient to solve this, provide a cost crd that also accepts the labels, like any other CRD producing costs like the ones i mentioned in my Issue.

@dwbrown2
Copy link

dwbrown2 commented Dec 6, 2024

I tend to agree that labels/annotations could be a powerful way to approach this. We could even use some of the FOCUS spec terms. @ameijer any views on your end?

I really think there are many interesting use cases here, including many around Crossplane.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants