Skip to content

Instantly share code, notes, and snippets.

View ardyantohermawan's full-sized avatar

Ardyanto Hermawan ardyantohermawan

View GitHub Profile
@ardyantohermawan
ardyantohermawan / docker-installer.sh
Last active September 6, 2016 13:12
Install docker-engine on Ubuntu 14.04 LTS
#!/bin/bash
sudo apt-get update -y
sudo apt-get install -y apt-transport-https ca-certificates
sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
sudo echo "deb https://apt.dockerproject.org/repo ubuntu-trusty main" > /etc/apt/sources.list.d/docker.list
sudo apt-get -y update
sudo apt-get -y install linux-image-extra-$(uname -r)
sudo apt-get -y update
#!/bin/bash
sudo apt-get install python-pip
sudo pip install virtualenv
mkdir dcos && cd dcos
curl -O https://downloads.dcos.io/dcos-cli/install.sh
bash install.sh . http://192.168.50.30:8080
dcos config prepend package.sources https://github.com/mesosphere/universe/archive/version-2.x.zip
@ardyantohermawan
ardyantohermawan / marathon-haproxy-bridge
Last active September 21, 2016 12:37
Install haproxy bridge for Marathon
#!/bin/bash
set -o errexit -o nounset -o pipefail
##########################################################
# DEPRECATION WARNING: This script has been deprecated. #
# #
# Please use marathon-lb instead: #
# https://github.com/mesosphere/marathon-lb #
##########################################################
@ardyantohermawan
ardyantohermawan / mesosphere-installer.sh
Last active September 8, 2016 07:39
mesosphere installation
#!/bin/bash
sudo /bin/bash install-java.sh
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv E56151BF
DISTRO=$(lsb_release -is | tr '[:upper:]' '[:lower:]')
CODENAME=$(lsb_release -cs)
# Add the repository
echo "deb http://repos.mesosphere.com/${DISTRO} ${CODENAME} main" | \
@ardyantohermawan
ardyantohermawan / GettingStarted.go
Created July 27, 2016 07:22 — forked from beccam/GettingStarted.go
Getting Started with Apace Cassandra and Go
package main
import (
"fmt"
"log"
"github.com/gocql/gocql"
)
func main() {
@ardyantohermawan
ardyantohermawan / install-sbt.sh
Created July 28, 2016 11:39
Install sbt on Ubuntu 14.04 LTS
#!/bin/bash
echo "deb https://dl.bintray.com/sbt/debian /" | sudo tee -a /etc/apt/sources.list.d/sbt.list
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 642AC823
sudo apt-get update
sudo apt-get install sbt
@ardyantohermawan
ardyantohermawan / install-java.sh
Last active July 31, 2019 12:19
Install openjdk 8 on ubuntu 14.04
#!/bin/bash
sudo add-apt-repository ppa:openjdk-r/ppa
sudo apt-get -y update
sudo apt-get install -y openjdk-8-jdk
@ardyantohermawan
ardyantohermawan / mesos-slave-setting.sh
Last active July 4, 2017 10:07
Setting mesos-slave
#!/bin/bash
# install java 8
sudo add-apt-repository ppa:openjdk-r/ppa
sudo apt-get -y update
sudo apt-get install -y openjdk-8-jdk
# install zookeper, mesos, marathon, chronos
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv E56151BF
DISTRO=$(lsb_release -is | tr '[:upper:]' '[:lower:]')
package main
import (
"fmt"
"github.com/rhinoman/couchdb-go"
"time"
)
type APICall struct {
AppId string `json:"appId"`
@ardyantohermawan
ardyantohermawan / golang_job_queue.md
Created February 7, 2017 04:35 — forked from harlow/golang_job_queue.md
Job queues in Golang