Skip to content

Getting Started

This guide gets you from an empty GitOps source project to rendered Kubernetes manifests, then points you at the workflow that matches how you deploy.

Add Nyl to your mise.toml:

[tools."github:NiklasRosenstein/nyl"]
version = "0.4.1"
version_prefix = "v"

Then install it:

Terminal window
mise install
Terminal window
curl -LO https://github.com/NiklasRosenstein/nyl/releases/latest/download/nyl-x86_64-unknown-linux-gnu.tar.gz
tar xzf nyl-x86_64-unknown-linux-gnu.tar.gz
sudo mv nyl /usr/local/bin/
Terminal window
cd nyl
cargo build --release

The binary will be available at nyl/target/release/nyl when building from the repository root.

Terminal window
cd nyl
cargo install --path .

This installs nyl to ~/.cargo/bin/nyl.

Terminal window
nyl new project platform
cd platform

This creates:

  • nyl.toml - Project configuration
  • components/ - Directory for components
Terminal window
nyl new component v1.example.io MyApp

This creates a new local component at components/v1.example.io/MyApp/ with:

  • Chart.yaml - Helm chart metadata
  • values.yaml - Default values
  • values.schema.json - JSON schema for validation
  • templates/deployment.yaml - Kubernetes deployment template
Terminal window
nyl validate

Output:

✓ Found project config: /path/to/platform/nyl.toml
✓ Components search path exists: /path/to/platform/components
✓ Helm chart search path exists: /path/to/platform
✓ Validation passed

For CI, use strict mode to treat warnings as errors:

Terminal window
nyl validate --strict

Render a manifest file to stdout:

Terminal window
nyl render apps.yaml

For deterministic CI rendering without cluster discovery, use offline mode. If your nyl.toml defines [project.kubernetes] or [profile.<name>.kubernetes], Nyl uses those values automatically:

Terminal window
nyl render --offline -p dev apps.yaml
platform/
├── nyl.toml # Project configuration
├── components/ # Component definitions
│ └── v1.example.io/
│ └── MyApp/
│ ├── Chart.yaml
│ ├── values.yaml
│ ├── values.schema.json
│ └── templates/
│ └── deployment.yaml
└── charts/ # Optional: additional Helm chart search path