Great question from today about automating embedded KOTS app manager installs for headless installations.
Hey everyone. Is it possible to use apply config-values to an embedded installation like it is done here for an existing cluster installation? Installing with Automation | Replicated Docs
Solution
For embedded clusters, the same command from the example can be used. You can add additional flags as needed. The kots CLI will be pre-installed on any kurl.sh cluster that includes the kotsadm addon.
Background
Thanks @Stefan_Reinprecht for asking a great clarifying question here â hereâs some additional context:
When you install with curl | bash â you do install the KOTS admin console but the only thing thatâs unique to âyour appâ at that point is the App name and Icon. No other app components are installed until a license is uploaded.
While it may seem strange to do a curl | bash install for K8s + KOTS, and then do a kots install command again later, this is by design. This ensures you (and your users) can re-use the same tools in both embedded and existing cluster without having to learn two sets of commands or flags.
Thanks for this post @dex very useful.
Iâve been deploying apps using automation for a while but been doing the last mile config via the kotsadm web UI, noticed the --configvalues option on your linked docs example, initially not sure what the syntax would be for that file and found I could pull an example for my deployed app using
kubectl kots get config --appslug <app slug> -n <deployed namespace>
@dex My problem is, that after running the initial installation via curl -sSL https://k8s.kurl.sh/APP_SLUG | sudo bash the application will be installed. I for sure can afterwards remove the installation again and redo it with the kubeclt kots command that you linked to, but that doesnât feel right. I hoped that I could pass some arguments into the installer like with the flag for âairgappedâ.
Hi Stefan â thatâs a good callout â Iâll clarify here and then update the original post.
When you install with curl | bash â you do install the KOTS admin console but the only thing thatâs unique to âyour appâ at that point is the App name and Icon. No other app components are installed until a license is uploaded.
While it may seem strange to do a curl | bash install for K8s + KOTS, and then do a kots install command again later, this is by design to ensure you can re-use the same tools in both embedded and existing cluster without having to learn two sets of commands or flags.
⢠Deploying Admin Console
⢠Waiting for Admin Console to be ready â
⢠Done
The only thing which is happening is that the kotsadm-0 pod gets restarted. But the application is not installed. I tried to reuse the default namespace of K8s.
@Stefan_Reinprecht this may just be a copy-paste issue, but from here it looks like you lost the newlines in the command? If you run it without the line breaks, you need to remove the \ in between each argument.