Skip to content

Commit ea5e7b2

Browse files
authored
docs: add local KOTS CLI development guide (#3101)
docs: add local KOTS CLI dev guide
1 parent 49bfe91 commit ea5e7b2

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

README.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -344,6 +344,44 @@ make initial-release
344344
make kurl-proxy-down-ec
345345
```
346346
347+
### Using Local KOTS CLI for Development
348+
349+
When developing embedded cluster, you can use your local kots CLI binary instead of the default one. This is particularly useful when you need to test changes to the kots CLI itself.
350+
351+
#### Setting Up Local KOTS Binary
352+
353+
1. **Build your local kots binary** in the kots repository:
354+
```bash
355+
make kots-linux-arm64
356+
```
357+
358+
2. **Update `versions.mk`** to set the override:
359+
```makefile
360+
KOTS_BINARY_FILE_OVERRIDE = ../kots/bin/kots
361+
```
362+
363+
#### Alternative: Remote Binary Override
364+
365+
1. In the kots repository, build and upload your kots binary to ttl.sh by running:
366+
```bash
367+
make kots-ttl.sh
368+
```
369+
This will print a ttl.sh URL for the uploaded kots binary.
370+
371+
2. In `versions.mk` file, set the override variable to the printed URL:
372+
```makefile
373+
KOTS_BINARY_URL_OVERRIDE = ttl.sh/<user>/kots.tar.gz:24h
374+
```
375+
376+
#### How It Works
377+
378+
The build system checks for overrides in this order:
379+
1. `KOTS_BINARY_URL_OVERRIDE` - Downloads from URL (supports HTTP/HTTPS and ttl.sh artifacts)
380+
2. `KOTS_BINARY_FILE_OVERRIDE` - Uses local file directly
381+
3. Default - Downloads from kotsadm Docker image
382+
383+
The system automatically generates a KOTS version string based on your override, ensuring proper versioning for development builds on rebuilds.
384+
347385
## Dependency Versions
348386
349387
The [versions.mk](versions.mk) file serves as the single source of truth for all external dependency versions.

0 commit comments

Comments
 (0)