Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/tilt-dev/ctlptl

Making local Kubernetes clusters fun and easy to set up
https://github.com/tilt-dev/ctlptl

Last synced: 5 days ago
JSON representation

Making local Kubernetes clusters fun and easy to set up

Awesome Lists containing this project

README

        

# ctlptl

[![Build Status](https://circleci.com/gh/tilt-dev/ctlptl/tree/main.svg?style=shield)](https://circleci.com/gh/tilt-dev/ctlptl)
[![GoDoc](https://godoc.org/github.com/tilt-dev/ctlptl?status.svg)](https://pkg.go.dev/github.com/tilt-dev/ctlptl)

Want to mess around with Kubernetes, but don't want to spend an ocean on
hardware?

Maybe you need a `ctlptl`.

## What is ctlptl?

`ctlptl` (pronounced "cattle patrol") is a CLI for declaratively setting up
local Kubernetes clusters.

Inspired by `kubectl` and
[ClusterAPI's](https://github.com/kubernetes-sigs/cluster-api) `clusterctl`, you
declare your local cluster with YAML and use `ctlptl` to set it up.

## How do I install it?

Install your cluster of choice: [Docker for
Desktop](https://www.docker.com/products/docker-desktop),
[Kind](https://kind.sigs.k8s.io/),
[k3d](https://k3d.io/) or
[Minikube](https://minikube.sigs.k8s.io/). Then run:

### Homebrew (Mac/Linux)

```
brew install tilt-dev/tap/ctlptl
```

### Scoop (Windows)

```
scoop bucket add tilt-dev https://github.com/tilt-dev/scoop-bucket
scoop install ctlptl
```

### Go install

```
go install github.com/tilt-dev/ctlptl/cmd/ctlptl@latest
```

### Alternative Options

If automatic installers aren't your cup of tea, check out the [installation
appendix](INSTALL.md) for more options.

## How do I use it?

`ctlptl` supports 4 major commands:

- `ctlptl get` - see all running clusters
- `ctlptl create cluster [product]` - create a cluster and make it the current `kubectl` context
- `ctlptl apply -f cluster.yaml` - ensure a cluster exists, or create one
- `ctlptl delete -f cluster.yaml` - delete a cluster and its state

### Examples

#### Docker for Mac: Enable Kubernetes and set 4 CPU

Create:

```
ctlptl docker-desktop open
ctlptl create cluster docker-desktop --min-cpus=4
```

or ensure exists:

```
cat <