Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/farcaller/nix-kube-generators
A set of functions helping to generate k8s yamls.
https://github.com/farcaller/nix-kube-generators
helm kubernetes nix
Last synced: 3 months ago
JSON representation
A set of functions helping to generate k8s yamls.
- Host: GitHub
- URL: https://github.com/farcaller/nix-kube-generators
- Owner: farcaller
- License: apache-2.0
- Created: 2022-12-09T17:30:51.000Z (about 2 years ago)
- Default Branch: master
- Last Pushed: 2024-02-17T07:36:37.000Z (12 months ago)
- Last Synced: 2024-04-13T15:53:54.551Z (10 months ago)
- Topics: helm, kubernetes, nix
- Language: Nix
- Homepage:
- Size: 21.5 KB
- Stars: 11
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# nix kube generators
A set of functions helping to generate k8s yaml. just pass pkgs along to the
lib function:```nix
kubelib = nix-kube-generators.lib { inherit pkgs; };
```## Functions
### FromYAML [yaml]
Parse a YAML string. If source YAML has several documents a list of them
is returned.### toYAMLFile [object]
Serialize the object into a YAML file.
Note that generally builtins.toJSON _is_ a valid YAML. This function is
only to be used for extra readability.### DownloadHelmChart [repo] [chart] [version] ([chartHash])
Download a helm chart. This can used indrectly with charts via
[nixhelm](https://github.com/farcaller/nixhelm). The correct chartHash
must be specified. To evaluate it, build the derivation without the hash first
(or with a wrong hash).### BuildHelmChart [name] [chart] ([namespace] [values] [includeCRDs] [kubeVersion] [apiVersions])
Build a YAML containing the evaluated chart.
Chart should point to a directory with the chart source(or directly pass
`downloadHelmChart` result).### fromHelm
Build a helm chart and return it as parsed YAML. Accepts the same arguments
as buildHelmChart.