Deploying Docker Compose setups to Kubernetes through the UI

cmoyroud

Cadet
Joined
Dec 11, 2020
Messages
9
Hello,

Similar to many other people, I'm really excited by the all-in-one aspect of SCALE. Like others, I have a VM just to run my Docker Compose stack, and I'd want to have SCALE host that natively. Since it uses Kubernetes by default, using Helm charts (I'm using these at work) seems the correct choice.

There's a tool to convert Docker Compose files to run on Kubernetes, called Kompose. The default is to generate K8s YAML files, but there's also an option to create Helm charts.

Could you guys consider plugging this in the UI? That would be a fantastic upgrade path for many people.
 

morganL

Captain Morgan
Administrator
Moderator
iXsystems
Joined
Mar 10, 2018
Messages
2,694
We're adding the 1st Kubernetes part of the WebUI in the next few days. It will include a way of running a Docker container and automatically generating the Helm chart. It will be in the 20.12 NIGHTLY images and then in the 20.12 release (next week). It was the last feature we added the requirement we had before release.

Sounds exactly like what you are asking for? Look forward to getting you feedback.
 

cmoyroud

Cadet
Joined
Dec 11, 2020
Messages
9
Hi Morgan,

What is currently available through the UI and CLI is the first step - it only works to deploy a single container/pod. Docker Compose is usually employed to deploy multiple containers, so it maps well to deploying multiple pods to Kubernetes.

For example, my Docker Compose setup has containers for multiple VPN containers, a Unifi controller, a Wiki, etc. With Kompose, this multiple-container setup would be transcribed to a Helm chart that creates multiple pods.

Cheers,

Clément
 

morganL

Captain Morgan
Administrator
Moderator
iXsystems
Joined
Mar 10, 2018
Messages
2,694
Hi Morgan,

What is currently available through the UI and CLI is the first step - it only works to deploy a single container/pod. Docker Compose is usually employed to deploy multiple containers, so it maps well to deploying multiple pods to Kubernetes.

For example, my Docker Compose setup has containers for multiple VPN containers, a Unifi controller, a Wiki, etc. With Kompose, this multiple-container setup would be transcribed to a Helm chart that creates multiple pods.

Cheers,

Clément

Can you run Kompose to create the Helm charts to use with TrueNAS SCALE? If not, what is missing/needed?
 

cmoyroud

Cadet
Joined
Dec 11, 2020
Messages
9
Yep, I definitively could right now (I still have to try it in a SCALE VM though). Having it in the WebUI is the part I think would be awesome. Not a high priority item, just a nice-to-have down the line.
 

morganL

Captain Morgan
Administrator
Moderator
iXsystems
Joined
Mar 10, 2018
Messages
2,694
Yep, I definitively could right now (I still have to try it in a SCALE VM though). Having it in the WebUI is the part I think would be awesome. Not a high priority item, just a nice-to-have down the line.
Try it out with new UI.. Suggest you document what is needed now....and then suggest what would make it better. Then you can "make a suggestion" in the "bug tracking" system.
 

j_r0dd

Contributor
Joined
Jan 26, 2015
Messages
134
I used kompose to convert my docker-compose files, which did the hard part nicely. I take it that we will need the helm charts file created as well. Are there any known pitfalls to importing these in the cli? Manually creating each container/pod in the gui would be very time consuming.
 

ornias

Wizard
Joined
Mar 6, 2020
Messages
1,458
I used kompose to convert my docker-compose files, which did the hard part nicely. I take it that we will need the helm charts file created as well. Are there any known pitfalls to importing these in the cli? Manually creating each container/pod in the gui would be very time consuming.
Mostly:
- Kompose does not always do this perfectly, be ready to trace bugs
- Be aware there are currently no GUI tools at all for you to do anything with your deployed charts.
 

j_r0dd

Contributor
Joined
Jan 26, 2015
Messages
134
Mostly:
- Kompose does not always do this perfectly, be ready to trace bugs
- Be aware there are currently no GUI tools at all for you to do anything with your deployed charts.

Yeah I found out last night kompose did not parse everything correctly, like sysctls, volumes & network_mode. I'm perfectly comfortable working with this in cli. I know it's always been best practice to do everything within the gui for TrueNAS. The gui would be rather cumbersome to manually enter every parameter for each pod/container, but I also don't want to break the gui in the process or not be persistent. I have no plan of tweaking the default k3s stack. I just want to get all my ducks in a row before migrating to SCALE.
 

Inabon

Dabbler
Joined
Dec 22, 2017
Messages
14
We're adding the 1st Kubernetes part of the WebUI in the next few days. It will include a way of running a Docker container and automatically generating the Helm chart. It will be in the 20.12 NIGHTLY images and then in the 20.12 release (next week). It was the last feature we added the requirement we had before release.

Sounds exactly like what you are asking for? Look forward to getting you feedback.
what is the way to run it? the blue button? there is no documentation on it can you point me where to read and use I want to install machinaris 6.7 version the one you have is outdated and no way to update.
 

morganL

Captain Morgan
Administrator
Moderator
iXsystems
Joined
Mar 10, 2018
Messages
2,694
Some progress on Docker-Compose via a TrueCharts App.
 
Top