kylemcc / kube-gen Goto Github PK
View Code? Open in Web Editor NEWGenerate files from Kubernetes events
License: BSD 3-Clause "New" or "Revised" License
Generate files from Kubernetes events
License: BSD 3-Clause "New" or "Revised" License
Hi ,
Thanks for the awesome job ! This is very useful.
Can you please provide some working example of templates ? How to uses functions and stuff , how to get annotation from ingress for example.
That would be very useful !
Thanks
There may be underlying reasons why this wasn't included at some point, but seeing as the Sprig library is pretty well maintained, it would make sense to include it with the kube-gen
template processor.
https://github.com/Masterminds/sprig
I think it only requires adding the following here
Line 3 in 5534ca5
import (
"github.com/Masterminds/sprig/v3"
"html/template"
)
and merging these functions here
Line 17 in 5534ca5
tpl := template.Must(
template.New("base").Funcs(sprig.FuncMap()).ParseGlob("*.html")
)
The kubernetes client is getting pretty ancient, and should be upgraded to a modern version.
https://github.com/kubernetes/client-go
Current version is
https://github.com/kylemcc/kube-gen/blob/16e1462f32d6feb6419dacfdaa52789188de2cd6/go.mod#L9C26-L10C1
from
https://github.com/kubernetes/client-go/releases/tag/v0.24.2
Currently it seems that kube-gen
requires a ClusterRole
in order to work. It appears that there aren't any controls for limiting the scope of kube-gen
to a specific namespace.
For our use case, we want to run https://github.com/kylemcc/kube-nginx-proxy in certain namespaces, and only generate nginx configurations for services / pods within the same namespace. In this scenario, we would also want to only use namespace scoped roles, not cluster scoped roles.
Is this currently possible? Maybe using environment variables or undocumented flags?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.