Draft: Add basic devspace config for runner
What does this merge request do and why?
This is an early draft of how DevSpace integration for satellite projects could look like.
This would allow us to deploy a subset of our services into an arbitrary K8S cluster.
How to set up and validate locally
- Install K3D (or minikube)
- Run
k3d cluster create gdk-cluster --k3s-arg "--disable=traefik@server:0"
or create aminikube
cluster. - Register a runner, as per the documentation
- Run
gdk config set kubernetes.enabled true
(Maybe we don't need this step in the future?) - Run
gdk config set runner.token
with your token - Run
gdk config set runner.enabled true
- Run
gdk config set runner.install_mode kubernetes
- Run
gdk config set kubernetes.context
with a suitable value from the lists of contexts inkubectl config get-contexts
. Minikube and K3D should both have set up such a context. - Run
gdk reconfigure
&&gdk restart runner
- Run
gdk tail runner
Mind the following current limitations:
- The service will enter a kind of restart loop, if the pod restarts frequently (or an image can't be pulled for whatever reason). This is, because we attach to the pod's logs to have something "in the foreground", to make
runit
happy. -
runit
has no idea how to correctly terminate a pod.gdk stop runner
will not stop it. It will only stop the foreground process. - In order to really stop it:
gdk stop runner; DEVSPACE_CONFIG=devspace/runner.yml devspace purge
Impacted categories
The following categories relate to this merge request:
-
gdk-reliability - e.g. When a GDK action fails to complete. -
gdk-usability - e.g. Improvements or suggestions around how the GDK functions. -
gdk-performance - e.g. When a GDK action is slow or times out.
Merge request checklist
-
This MR references an issue describing the change. -
This change is backward compatible. If not, please include steps to communicate to our users. -
Tests added for new functionality. If not, please raise an issue to follow-up. -
Documentation added/updated, if needed. -
Announcement added, if change is notable. -
gdk doctor
test added, if needed.