Skip to content

Instantly share code, notes, and snippets.

View dky's full-sized avatar
🍜

dky

🍜
View GitHub Profile
version: '3.1'
services:
grafana:
image: grafana/grafana:latest
container_name: grafana
restart: always
environment:
- "GF_SECURITY_ADMIN_PASSWORD=install"
ports:
dky@mbp ~/bin (master) $ docker run -it alpine:3.13.2
/ # apk update && apk upgrade && apk add git
fetch https://dl-cdn.alpinelinux.org/alpine/v3.13/main/x86_64/APKINDEX.tar.gz
fetch https://dl-cdn.alpinelinux.org/alpine/v3.13/community/x86_64/APKINDEX.tar.gz
v3.13.5-312-g734ede2fa6 [https://dl-cdn.alpinelinux.org/alpine/v3.13/main]
v3.13.5-312-g734ede2fa6 [https://dl-cdn.alpinelinux.org/alpine/v3.13/community]
OK: 13897 distinct packages available
Upgrading critical system libraries and apk-tools:
(1/1) Upgrading apk-tools (2.12.1-r0 -> 2.12.7-r0)
Executing busybox-1.32.1-r3.trigger
@dky
dky / tmux
Last active August 30, 2021 12:28
#!/bin/bash
TMUX=`which tmux`
USER=`whoami`
DOTFILES_DIR=~/.dotfiles
GIT_DIR=~/git
GO_DIR=~/go/src/github.com/dky
function mux_up {
version: '3.7'
services:
consul-server:
image: consul:1.10.1
network_mode: host
container_name: consul
restart: always
command: 'agent -bind=192.168.4.2 -server -client=0.0.0.0 -bootstrap-expect=1 -node=nyc3-1 -ui -datacenter=nyc3'
client {
enabled = false
servers = ["127.0.0.1"]
}
server {
enabled = true
bootstrap_expect = 1
}
version: '3.7'
services:
nomad:
container_name: nomad
restart: always
image: dkyio/nomad:1.1.3
command: agent
privileged: true
network_mode: host

Keybase proof

I hereby claim:

  • I am dky on github.
  • I am dky (https://keybase.io/dky) on keybase.
  • I have a public key whose fingerprint is B263 DF44 5355 E279 8E70 E4CC 10A4 6019 A1E5 C18C

To claim this, I am signing this object:

@dky
dky / main.go
Created January 16, 2018 13:43 — forked from enricofoltran/main.go
A simple golang web server with basic logging, tracing, health check, graceful shutdown and zero dependencies
package main
import (
"context"
"flag"
"fmt"
"log"
"net/http"
"os"
"os/signal"
@dky
dky / install_splunk.sh
Created May 19, 2016 14:39 — forked from stamler/install_splunk.sh
Install Splunk Enterprise 6.2 on CentOS 7 Minimal as a non-root user systemd service and enable syslog on port 514 and http on port 80
#!/bin/bash
# Install Splunk 6.2 on CentOS 7 as a non-root user service that runs on boot with
# systemd. This script also opens the firewall to allow syslog on UDP port 514. Since
# we're running Splunk as non-root, this port is then forwarded to 5514. Configuring a
# syslog input in slunk on UDP 514 will gather this data. Must be run as root
# Create Account
useradd splunk
groupadd splunk
@dky
dky / gist:fd04b0a11b5ecfb85228
Last active August 29, 2015 14:23
Install brew with python and lua
brew install vim --with-lua