News for hackers. Stuff that matters.
Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by praseodym on Tuesday March 13, 2018 @08:52AM (#16575687)
We’ve been using a similar solution for a while now: pushes to GitHub trigger Travis CI to build a Docker images. These get pushed to Docker Hub or Quay, which triggers a webhook to Keel.sh[1] running in our Kubernetes cluster. Keel then updates the Kubernetes deployment to perform a rolling update of the application.

1: https://keel.sh

Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by deforciant on Tuesday March 13, 2018 @09:26AM (#16575883)
Thanks for the shout-out! Keel author here. I have created Keel exactly for these workflows where something (Travis CI, Docker cloud, Google Cloud Builder - my favourite due to the pricing and proper speed) builds an image and then we would want to trigger a deployment update.

I was running workloads on GKE and I found that while it's easy to get images being built, there was no straightforward way to automate deployment updates. My goal was to tag a release on Github and get a new version deployed in my environment. After searching for similar tools and couldn't find anything lightweight (spinnaker or jenkins were way too big!) I ended up building Keel.

Here's an example if anyone has this problem https://keel.sh/v1/examples/enabling-auto-updates.html.

Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by antoncohen on Tuesday March 13, 2018 @02:07PM (#16578268)
Keel looks nice, thanks for making it!

Does Keel include any ability to rollback to a previously deployed version? How to you recommend handling that use case?

Keel looks similar to Weave Flux (https://github.com/weaveworks/flux). Have you looked at Flux, are you able to compare them? At first glance it looks like Keel is probably easier to setup, but Flux is more feature rich (edits k8s .yaml files in git with updated image tags, has CLI that supports listing deployments and images, can release an old image).

Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by dankohn1 on Tuesday March 13, 2018 @11:49PM (#16582129)
CNCF is currently tracking 27 offerings in the CI/CD space, of which 13 are open source: https://landscape.cncf.io/grouping=landscape&landscape=ci-cd
Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by cheez on Tuesday March 13, 2018 @12:50PM (#16577527)
What is it we can achieve with Keel that we can't with Terraform?
Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by alexnewman on Tuesday March 13, 2018 @01:40PM (#16578010)
Or by awk for that matter. Sorry to be silly but terraform solves a completely different problem, which is what happens when you have disparate cloud resources you want to manage. For instance cloud network resources. Using it to manage containers is... Not it's use case.
Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by alberteinstein on Tuesday March 13, 2018 @11:43AM (#16577048)
Gitkube is simpler since everything is contained in the cluster itself. Image is built and rolled out from within the cluster right now. (gitkube contributor here)
Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by tirumaraiselvan on Tuesday March 13, 2018 @09:40AM (#16575978)
Hey!

Just curious, why not have Travis CI do a kubectl set-image to rollout after pushing the docker image?

Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by praseodym on Tuesday March 13, 2018 @11:10AM (#16576711)
Our Kubernetes API server is only reachable from the internal network, which complicates things. Also, setting up Kubernetes RBAC to allow Travis CI to do a kubectl set-image isn’t trivial either.

The best alternative would be to have Travis CI SSH into a box with kubectl. In any case it’s bit more complicated than the setup with Keel we currently have.

Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by ecthiender on Tuesday March 13, 2018 @11:44AM (#16577058)
> Also, setting up Kubernetes RBAC to allow Travis CI to do a kubectl set-image isn’t trivial either.

Wouldn't setting up Keel on a Kubernetes cluster be the same effort (permissions, RBAC etc.)?

Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by praseodym on Tuesday March 13, 2018 @02:54PM (#16578746)
Keel has permissions to update all deployments in our cluster. Because it runs within the cluster instead of outside (like Travis CI), and the only interaction with Keel is through webhooks, there is no need for finegrained RBAC.

The webhooks only tell Keel that a new image is available, they cannot modify other parts of the Kubernetes deployment directly.

Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by tirumaraiselvan on Tuesday March 13, 2018 @12:02PM (#16577199)
On that note, Gitkube supports RBAC as the Remote objects are namespaced. This means two things:

1) Remotes are isolated - have different authorizations for say dev and staging remotes

2) Deployments are isolated - A Remote can only deploy apps in its own namespace.

Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by hashfyre on Wednesday March 14, 2018 @05:16AM (#16583375)
We are doing the exact same thing with Drone CI, however RBAC on the cluster is needed.

RBAC isn't too complicated though:

- get on specific app namespaces

- get, list, watch, patch, update on deployments

Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by 1_player on Tuesday March 13, 2018 @09:54AM (#16576075)
Do you know of a tool like Keel, but for Docker Swarm?
Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by deforciant on Tuesday March 13, 2018 @10:34AM (#16576413)
Hi, if you would want Keel to support Docker Swarm, please create an issue here: https://github.com/keel-hq/keel/issues.

I planned to add Docker Swarm support from the beginning but a lot of people said that it's unnecessary. It's quite simple to add new providers, they need to implement this interface:

  // Provider - generic provider interface
  type Provider interface {
 	Submit(event types.Event) error  // <- this is where new image event comes in
	TrackedImages() ([]*types.TrackedImage, error) // <- provider needs to tell some triggers which images to track (registry watcher)
	GetName() string
	Stop()
  }


Even though Keel was created for Kubernetes, later on Helm was added where Keel talks directly to Tiller and doesn't really use K8s API.
Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by BretFisher on Wednesday March 14, 2018 @11:58PM (#16590320)
Maybe https://github.com/v2tec/watchtower, but Keel looks cool.
Re:Show HN: Gitkube – Deploy to Kubernetes Using Git Push by 1_player on Thursday March 15, 2018 @11:31AM (#16593691)
Doesn't support Swarm, but thanks for the pointer.