The Signal Pattern

The signal pattern can be used to ensure your long-lived processes (ie. servers) are able to handle signals being sent to the process.

»
Author's profile picture David Chua on golang

Sending your Structs across the wire (tcp connection)

Sending your structs across the wire and receiving them on the other side. Using encoding/gob can help ensure your data structures can receive it on the other side.

»
Author's profile picture David Chua on golang

Using S2i like buildpacks to deploy apps

Openshift’s S2i (Source-2-image) is a pretty cool replacement to buildpacks using Dockerfiles and Openshift

»
Author's profile picture David Chua on guides

Load env variables from ConfigMaps and Secrets upon Pod boot

One of the coolest stuff I’ve picked up just today is that you can keep environment variables that you want to be loaded into every deployment pod in a neatly configured ConfigMap or Secret which gets injected back into the Pod during deploys.

»
Author's profile picture David Chua on guides

How to access unexported embedded structs within composite literals in Golang

Short Answer, you can’t. BUT you can still declare it.

»
Author's profile picture David Chua on guides

Forwarding Vault audit logs to a remote Syslog server (like Graylog)

Using Vault’s Audit Backend to send logs to a remote Syslog server.

»
Author's profile picture David Chua on guide

Alerting with Prometheus and AlertManager

How to setup Prometheus AlertManager and get a whole alerting pipeline setup.

»
Author's profile picture David Chua on guides

Deleting files and getting your diskspace back without rebooting

When you run out of diskspaces and need to delete files quickly to recover them, most of the time, your deleted files will not free up the diskspace until the process that is using it is restarted or deleted.

»
Author's profile picture David Chua on guides

Using Multiple Buildpacks in Deis

To use multiple buildpacks with your Application Deployment on Deis Workflow, is pretty straight forward.

»
Author's profile picture David Chua on guide

Fixing OmniAuth Redirecting to a URI with Port

Came across this problem the other day when deploying a Rails application that is sitting behind Kubernetes and Deis

»
Author's profile picture David Chua on guide

Supercharge your Nginx with Openresty and Lua

Turn your Nginx into an API Gateway. Modify requests and responses from Nginx itself using Openresty and Lua.

»
Author's profile picture David Chua on guide

Monitor a Directory for File Changes with inotifywait

Sometimes there may be a need to monitor and be alerted when any new files have been added in a particular directory.

»
Author's profile picture David Chua on guides

Using Kubectl proxy to access your Kubernetes services

Sometimes it might be quite difficult to access your kubernetes services if your infrastructure isn’t able to properly support both LoadBalancer and NodePort service types.

»
Author's profile picture David Chua on guides

Running Deis on Digitalocean - A Nginx/Haproxy LB Setup

Digitalocean users generally tend to get the short end of the stick when it comes to convenience. When building your Deis cluster on Digitalocean, you’ll realize you don’t get the benefit of being able to provision cloud-provider specific load balancers like (AWS ELB, GCE Load Balancers) to route inbound traffic into the kubernetes cluster and into your deis-router.

»
Author's profile picture David Chua on guides

How to get Kubernetes and Deis onto Azure

With Kubernetes Anywhere, setting up a Kubernetes cluster on Microsoft’s Azure isn’t as painful as it used to be.

»
Author's profile picture David Chua on guide