Create a file called /media/state/units/docker-local.service
that has the following contents:
[Unit]
Description=docker local
[Service]
PermissionsStartOnly=true
g6Rib2R5hqhkZXRhY2hlZMOpaGFzaF90eXBlCqNrZXnEIwEgo3phlo0X1sVC5SmzHo525ANQKMrlP86o7Marckb6vhAKp3BheWxvYWTFAvh7ImJvZHkiOnsia2V5Ijp7ImVsZGVzdF9raWQiOiIwMTIwYTM3YTYxOTY4ZDE3ZDZjNTQyZTUyOWIzMWU4ZTc2ZTQwMzUwMjhjYWU1M2ZjZWE4ZWNjNmFiNzI0NmZhYmUxMDBhIiwiaG9zdCI6ImtleWJhc2UuaW8iLCJraWQiOiIwMTIwYTM3YTYxOTY4ZDE3ZDZjNTQyZTUyOWIzMWU4ZTc2ZTQwMzUwMjhjYWU1M2ZjZWE4ZWNjNmFiNzI0NmZhYmUxMDBhIiwidWlkIjoiYjYzZThkZjg2MWJmYzAxYzBiYzM1MWVhOTRkOTRkMTkiLCJ1c2VybmFtZSI6ImxvZ2ljYWxwYXJhZG94In0sInNlcnZpY2UiOnsibmFtZSI6ImdpdGh1YiIsInVzZXJuYW1lIjoibG9naWNhbHBhcmFkb3gifSwidHlwZSI6IndlYl9zZXJ2aWNlX2JpbmRpbmciLCJ2ZXJzaW9uIjoxfSwiY2xpZW50Ijp7Im5hbWUiOiJrZXliYXNlLmlvIGdvIGNsaWVudCIsInZlcnNpb24iOiIxLjAuMTUifSwiY3RpbWUiOjE0NjIzNzczMTYsImV4cGlyZV9pbiI6NTA0NTc2MDAwLCJtZXJrbGVfcm9vdCI6eyJjdGltZSI6MTQ2MjM3NzMwOCwiaGFzaCI6Ijc4NmJhM2EzNWJjZjQ4NDJiNjFmZjljMTI3ZmEyMmE5OGQyYjFmMzAyYjUwNmE3M2EwZDcwZTVhZGUyZmE5MDYwYmQ0YzQxYjU4YjMxMDZjYWFiNjQ2ODA4ZDFlNGZiYjE0NWRiMjRkN2Q5NDk1NTQxNjAyYWZhMGVjZjQ3NDA4Iiwic2Vxbm8iOjQ1Njg2OX0sInByZXYiOiIyYzhiY2UyZGQ1ZmYxY2VhNDc2ZTQ1 |
FROM logicalparadox/kibana:4.0.0-BETA2 | |
ADD run.sh /opt/ | |
RUN chmod +X /opt/run.sh | |
CMD [ "/opt/run.sh" ] |
#!/bin/bash | |
IFNET="eth0" | |
IPNET="8.8.8.8" | |
PORTS="20 21 25 80 8000 8888 12000 12001 12002 12003" | |
BANLIST="64.205.0.18" | |
if [ "$1" = "start" ]; then | |
echo "Starting firewall..." |
#!/bin/bash | |
function tip { echo -e '\E[37;44m'"\033[1m$1\033[0m"; } | |
set +h | |
umask 022 | |
export LFS="/srv/lfs/6.6" | |
export LC_ALL=POSIX | |
export LFS_TGT=$(uname -m)-lfs-linux-gnu | |
export PATH=/tools/bin:/bin:/usr/bin |
HOST=x86_64-unknown-linux-gnu | |
#TARGET=mips-unknown-linux-gnu | |
#CROSS_TOOL=$HOME/tmp/mips-2013.05/bin | |
#CXX=mips-linux-gnu-g++ | |
#CXXFLAGS="-shared -fPIC -mips32r2 -msoft-float -mabi=32" | |
#LLCFLAGS="-march=mips -mcpu=mips32r2 -soft-float -mattr=+mips32r2,+o32 -relocation-model=pic -disable-fp-elim -segmented-stacks" | |
TARGET=arm-unknown-linux-gnueabihf | |
CROSS_TOOL=$HOME/tmp/rpi-tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian/bin |
extern mod extra; | |
use extra::json::*; | |
/* | |
* This function manages to do absolutely no copying, which is pretty cool. | |
* | |
* "What are all those `'r`s?" you ask. Well, they're liftime parameters. They | |
* indicate how long something lasts (before it's freed). They can't change how | |
* long something lives for, they only allow you to tell the compiler stuff it |
/*! | |
* Import transmute | |
*/ | |
var transmute = require('transmute'); | |
/*! | |
* Base logger | |
*/ | |
These instructions will install salt-master and salt-cloud on recent Ubuntu releases. Consult the SaltStack Installation Documentation should you require instructions for other distributions.
echo deb http://ppa.launchpad.net/saltstack/salt/ubuntu `lsb_release -sc` main | sudo tee /etc/apt/sources.list.d/saltstack.list
Unionize lets you connect together docker containers in arbitrarily complex scenarios.
Just check those examples.
Let's create two containers, running the web tier and the database tier: