Skip to content

Instantly share code, notes, and snippets.

@graste
graste / backupToS3.sh
Created June 16, 2019 17:31 — forked from autoize/backupToS3.sh
NextCloud Backup to Amazon S3
#!/bin/sh
# NextCloud to Amazon S3 Backup Script
# Author: Autoize (autoize.com)
# This script creates an incremental backup of your NextCloud instance to Amazon S3.
# Amazon S3 is a highly redundant block storage service with versioning and lifecycle management features.
# Requirements
# - Amazon AWS Account and IAM User with AmazonS3FullAccess privilege
@graste
graste / svc_accnt_kubeconfig.bash
Created May 29, 2019 06:24 — forked from yuval-k/svc_accnt_kubeconfig.bash
Get a kubeconfig with service account permissions. This is useful to test\debug kube RBAC issues locally.
#!/bin/bash
# script by http://github.com/yuval-k/ to get a kubeconfig with service account permissions
# this is useful to test\debug RBAC issues locally.
# get the latest version here: https://gist.github.com/yuval-k/1604b99f2ecd767c29983acc6470d5d6
# license: public domain.
NS=${NS:-$1}
SVCACCNT=${SVCACCNT:-$2}
@graste
graste / deployment-couchdb.yaml
Created May 27, 2019 14:33 — forked from kocolosk/deployment-couchdb.yaml
CouchDB 2.0 in Kubernetes
# Start a 3 node cluster and join it together automatically. Uses
# local ephemeral disk for database storage.
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: couchdb
spec:
replicas: 3
template:
@graste
graste / traefik-ds.yaml
Created May 27, 2019 08:47 — forked from ktsakalozos/traefik-ds.yaml
traefik deployment for MicroK8s
---
apiVersion: v1
kind: ServiceAccount
metadata:
name: traefik-ingress-controller
namespace: kube-system
---
kind: DaemonSet
apiVersion: extensions/v1beta1
metadata:
// Tracking cursor position in real-time without JavaScript
// Demo: https://twitter.com/davywtf/status/1124146339259002881
package main
import (
"fmt"
"net/http"
"strings"
)
@graste
graste / .block
Created March 10, 2019 08:17 — forked from mbostock/.block
Stacked Bar Chart
license: gpl-3.0
redirect: https://beta.observablehq.com/@mbostock/d3-stacked-bar-chart
@graste
graste / .block
Created March 10, 2019 08:17 — forked from mbostock/.block
Normalized Stacked Bar Chart
license: gpl-3.0
redirect: https://beta.observablehq.com/@mbostock/d3-stacked-normalized-horizontal-bar-chart
@graste
graste / .block
Created March 10, 2019 08:17 — forked from mbostock/.block
Difference Chart
license: gpl-3.0
redirect: https://beta.observablehq.com/@mbostock/d3-difference-chart
@graste
graste / .block
Created March 10, 2019 08:15 — forked from mbostock/.block
Force-Directed Graph with Mouseover
license: gpl-3.0
@graste
graste / .block
Created March 10, 2019 08:15 — forked from mbostock/.block
mousewheel-zoom + click-to-center
license: gpl-3.0