Skip to content

Instantly share code, notes, and snippets.

View nowylie's full-sized avatar

Nicholas Wylie nowylie

View GitHub Profile

The following sets up a local k3d cluster and deploys Postgres and Hasura GraphQL Engine.

NOTE: All data will be lost when containers restart

# Create the cluster mapping NodePorts to Host ports and set KUBECONFIG
k3d create --publish 5432:30032 --publish 8080:30080 --workers 2
export KUBECONFIG="$(k3d get-kubeconfig --name='k3s-default')"

# Deploy postgres
@nowylie
nowylie / utility.go
Created July 11, 2017 00:12
Why not just write a couple of utility functions?
package main
import (
"bytes"
"encoding/json"
"io"
"net/http"
)
type jsonMessage struct {