From ce81171198ad03ace9558984f9622336868d1b33 Mon Sep 17 00:00:00 2001
From: Michiel de Jong <michiel@unhosted.org>
Date: Thu, 4 Dec 2014 13:45:38 +0100
Subject: [PATCH] update bash-and-Docker instructions

---
 doc/using-just-docker-and-bash.md | 22 ++++++++++++----------
 1 file changed, 12 insertions(+), 10 deletions(-)

diff --git a/doc/using-just-docker-and-bash.md b/doc/using-just-docker-and-bash.md
index 5786f5f..3748425 100644
--- a/doc/using-just-docker-and-bash.md
+++ b/doc/using-just-docker-and-bash.md
@@ -3,34 +3,36 @@
 ## WARNING: Still a work-in-process
 
 Given that CoreOS is not available everywhere, and the Ubuntu 14.10 setup with etcdctl inside a Docker instance still has some problems,
-I'll try if I can run all our services (postfix-forwarder, haproxy, and the various web backend containers) on an off-the-shelf Ubuntu 14.04 server. Here's what I did to prepare the server:
+I'll try if I can run all our services (postfix-forwarder, haproxy, and the various web backend containers) on an off-the-shelf Ubuntu 14.04 server. Here's what I did to prepare the server (not all servers support Docker, because of kernel modules etcetera; I used Ubuntu 12.04-64 at Gandi, and gave it 5GB of disk space and 512Mb of RAM):
 
 ````bash
-apt-get update && apt-get -y upgrade && apt-get -y dist-upgrade
-apt-get -y install unattended-upgrades
+apt-get update && apt-get -y upgrade
+apt-get -y install unattended-upgrades curl git
 dpkg-reconfigure -plow unattended-upgrades
 # set unattended upgrades to 'Yes'
-apt-get -y install docker.io
+curl -s https://get.docker.io/ubuntu/ | sh
 ssh-keygen -t rsa
 ````
 
 Then I added the .ssh/id_rsa.pub to .ssh/authorized_keys at both backup server accounts, and ran:
 
 ````
-mkdir -p /data
-cd /data
 git clone git@bu25:postfix
+cd postfix; ./runme.sh; cd ..
 git clone git@bu25:haproxy
-docker run -d -v /data/haproxy:/etc/haproxy -p 80:80 -p 443:443 indiehosters/haproxy
-docker run -d --name postfix-forwarder -v /data/postfix:/data -p 25:25 indiehosters/postfix-forwarder 
+cd haproxy; ./runme.sh; cd ..
 ````
 
+TODO: document how to create and update such postfix and haproxy migration archives.
+
 And then for each domain I host:
 
 ````
 cd /data
 git clone git@bu25:michielbdejong.com
-docker run -d --name michielbdejong.com -v /data/michielbdejong.com:/data indiehosters/lamp-git
+cd michielbdejong.com; ./runme.sh --behind-haproxy; cd ..
 ````
 
-Now the only thing you need to do is to get each backend IP address from `docker inspect michielbdejong.com` and edit `/data/runtime/haproxy/haproxy.cfg` with the correct IP address.
+TODO: document how to create and update such web app migration archives.
+
+Now the only thing you need to do is to get each backend IP address from `docker inspect michielbdejong.com` and edit `/data/haproxy/haproxy.cfg` with the correct IP address (the idea of the `--behind-haproxy` flag would be to automate that; note that the migration format here does not include the postfix-forwarder, DNS, and DNR data).
-- 
GitLab