refactoring most of bootstrap into makefile. bootstrap supports branch checkouts, and using existing cloned dokku repos

This commit is contained in:
Jeff Lindsay
2013-07-02 03:12:43 -05:00
parent 19a0ee20e7
commit 2dfe1e1b05
3 changed files with 32 additions and 20 deletions

View File

@@ -1,22 +1,28 @@
GITRECEIVE_URL = https://raw.github.com/progrium/gitreceive/master/gitreceive
SSHCOMMAND_URL = https://raw.github.com/progrium/sshcommand/master/sshcommand
PLUGINHOOK_URL = https://s3.amazonaws.com/progrium-pluginhook/pluginhook_0.1.0_amd64.deb
DOCKER_URL = https://launchpad.net/~dotcloud/+archive/lxc-docker/+files/lxc-docker_0.4.2-1_amd64.deb
STACK_URL = https://s3.amazonaws.com/progrium-dokku/progrium_buildstep.tgz
all: install
all: install-all
install: gitreceive sshcommand pluginhook copy
install-all: dependencies stack install plugins
copy:
install:
cp dokku /usr/local/bin/dokku
cp receiver /home/git/receiver
plugins: pluginhook docker
mkdir -p /var/lib/dokku/plugins
cp -r plugins/* /var/lib/dokku/plugins
PLUGIN_PATH=/var/lib/dokku/plugins pluginhook install
dokku plugins
dependencies: gitreceive sshcommand pluginhook docker stack
gitreceive:
wget -qO /usr/local/bin/gitreceive ${GITRECEIVE_URL}
chmod +x /usr/local/bin/gitreceive
gitreceive init
test -f /home/git/receiver || gitreceive init
sshcommand:
wget -qO /usr/local/bin/sshcommand ${SSHCOMMAND_URL}
@@ -25,7 +31,17 @@ sshcommand:
pluginhook:
wget -qO /tmp/pluginhook_0.1.0_amd64.deb ${PLUGINHOOK_URL}
cd /tmp && dpkg -i pluginhook_0.1.0_amd64.deb
dpkg -i /tmp/pluginhook_0.1.0_amd64.deb
docker: aufs
wget -qO /tmp/lxc-docker_0.4.2-1_amd64.deb ${DOCKER_URL}
dpkg --force-depends -i /tmp/lxc-docker_0.4.2-1_amd64.deb && apt-get install -f -y
aufs:
modprobe aufs || apt-get install -y linux-image-extra-`uname -r`
stack:
@docker images | grep progrium/buildstep || curl ${STACK_URL} | gunzip -cd | docker import - progrium/buildstep
count:
@echo "Core lines:"