WARNING: Experimental - Do not use for realz
This is an attempt at using KyoML to generate Kubernetes manifests. KyoML is a dynamic markup language with support for custom directives and plugins.
Through the use of custom @directives
, this will generate a K8s compatible yaml file
Here's a sample kyoml deployment file
$ npm install
$ npm run dev -- [arguments]
Rendering a KyoML file into a K8s YAML:
$ npm run dev -- template ./sample.kyoml
apiVersion: apps/v1
kind: Deployment
metadata:
name: myapp
spec:
replicas: 1
template:
spec:
containers:
- name: hashicorp/http-echo
image: hashicorp/http-echo:latest
ports:
- containerPort: 80
Overriding values
$ npm run dev -- template ./sample.kyoml --image=myrepo/myimage
apiVersion: apps/v1
kind: Deployment
metadata:
name: myapp
spec:
replicas: 1
template:
spec:
containers:
- name: myrepo/myimage
image: myrepo/myimage:latest
ports:
- containerPort: 80