Using kubernetes driver with porter #1742
-
Hello everyone, I am trying to run a service using the porter sdk on k3s. There is no docker installed but containerd is. Referring to https://github.com/getporter/porter/blob/main/pkg/cnab/drivers/drivers.go#L21 In
is not sufficient. It will throw:
My other option would be to switch to k3s using docker instead of containerd but I wanted to evaluate my options with porter first. Best regards, Martin |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
The code in the porter operator repository is a proof of concept so any use bits of code are totally fair game to move into porter directly if we think the porter cli can use them too. So if we wanted to add support for I am actively working on getting porter altered so that we can support a proper operator. This will mean that porter itself will understand how to load files (that 99% match the operator's CRDs) for installations, credential sets and parameter sets, and then reconcile them. So that may be something to keep in mind as you are working on your service too. The situation is that the cnab-go library has a kubernetes driver, but it requires a lot of extra configuration to work properly. For example a volume for sharing files between the pod running the bundle and the pod where porter is orchestrating the bundle. The operator is currently taking care of setting all the required environment variables so that they are passed through to the cnab-go library. An official Porter Kubernetes driver would need to come up with a design for how the end user running porter should set these values (if any, maybe most can be calculated). Some questions you'd want to look at are:
Let me know if you are interested in working on this (even if it's just the design) or if this is a feature request. 😀 |
Beta Was this translation helpful? Give feedback.
-
Thank you for your response. Best regards Martin |
Beta Was this translation helpful? Give feedback.
The code in the porter operator repository is a proof of concept so any use bits of code are totally fair game to move into porter directly if we think the porter cli can use them too. So if we wanted to add support for
--driver kuberentes
, I'd be happy to chat more about how that should look and help someone get a PR merged with the changes.I am actively working on getting porter altered so that we can support a proper operator. This will mean that porter itself will understand how to load files (that 99% match the operator's CRDs) for installations, credential sets and parameter sets, and then reconcile them. So that may be something to keep in mind as you are working on your service too.