- Using Viper brings us lots of nice features, but also one problem:
- We had to switch StringArray flags to StringSlice flags, which
- allow to use multiple flag values comma-separated in a single flag, but also
- split flag values that contain a comma into separate parts (and we cannot handle issues that arise due to this)
- so if you rely on commas in your flag values (e.g. for `--env X=a,b,c`), please consider filing an issue or supporting <https://github.com/spf13/viper/issues/246> and <https://github.com/spf13/viper/pull/398>
- `--env X=a,b,c` would be treated the same as `--env X=a`, `--env b`, `--env c`
### Features & Enhancements
#### :scroll: Configuration Enhancements
- use [viper](https://github.com/spf13/viper) for configuration management
- :snake: use [viper](https://github.com/spf13/viper) for configuration management
- takes over the job of properly fetching and merging config options from
- CLI arguments/flags
- environment variables
- config file
- this also fixes some issues with using the config file (like cobra defaults overriding config file values)
- add JSON-Schema validation for the `Simple` config file schema
- new config version `k3d.io/v1alpha2` (some naming changes)
- :heavy_check_mark: add JSON-Schema validation for the `Simple` config file schema
- :new: config version `k3d.io/v1alpha2` (some naming changes)
- Support docker over SSH (#324, @ekristen&@inercia)
#### :computer: Docker over SSH
- Support Docker over SSH (#324, @ekristen&@inercia)
### Features & Enhancements
- add root flag `--timestamps` to enable timestamped logs
- improved multi-server cluster support (#467)
- log a warning, if one tries to create a cluster with only 2 nodes (no majority possible, no fault tolerance)
@ -45,7 +44,7 @@
- tests/e2e: improved logs with stage and test details.
- ci/drone+tests/e2e: use E2E_EXTRA=true to always test multiple k3s versions in CI
- builds&tests: use Docker 20.10 and BuildKit everywhere
- docs: add <https://github.com/AbsaOSS/k3d-action> (GitHub Action) as a related project (#476, @kuritka)
- :memo: docs: add <https://github.com/AbsaOSS/k3d-action> (GitHub Action) as a related project (#476, @kuritka)
### Tested with
@ -58,6 +57,12 @@
### Known Issues
- automatic multi-server cluster restarts tend to fail with k3s versions v1.17.x & v1.18.x and probably earlier versions (using dqlite)
- Using Viper brings us lots of nice features, but also one problem:
- We had to switch StringArray flags to StringSlice flags, which
- allow to use multiple flag values comma-separated in a single flag, but also
- split flag values that contain a comma into separate parts (and we cannot handle issues that arise due to this)
- so if you rely on commas in your flag values (e.g. for `--env X=a,b,c`), please consider filing an issue or supporting <https://github.com/spf13/viper/issues/246> and <https://github.com/spf13/viper/pull/398>
- `--env X=a,b,c` would be treated the same as `--env X=a`, `--env b`, `--env c`