Hacker News new | ask | show | jobs
by ImJasonH 956 days ago
Hey, ko maintainer here! I'd love to answer any questions or hear any feedback folks have.

Ko's simplicity comes from focusing on doing exactly one thing well -- it doesn't have to run containers to build code in any language, it just builds minimal Go containers, and that means it can focus on doing that as well as possible.

Another powerful benefit of focusing on Go (IMO) is that ko can be used to transform a Go importpath to a built image reference.

A common simple use: `docker run $(ko build ./cmd/app)`

This is also how Kubernetes YAML templating[1] works, and it's also how the Terraform provider[2] works -- you give it an importpath, and ko transforms it into a built image reference you can pass to the rest of your config. I don't even "use ko" day-to-day most days, I mostly just use terraform. :)

1: https://ko.build/features/k8s/ 2: https://ko.build/advanced/terraform/

2 comments

Ko works ok but lacks a lot of configurability, compared to something like jib, that does end up important. There are a few open issues on it but the commit history is basically dependabot, not much action for UX. Better than nothing I guess but it really does give off the feeling of a project spun off from Google to let it die.

Despite that it's probably still the best tool for building containers in Go, but it's not pleasant.

Hello Jason!