-
Notifications
You must be signed in to change notification settings - Fork 0
Home
Thomas @ BeeDesk edited this page Feb 12, 2015
·
9 revisions
Welcome to the docker-dokku wiki!
====
On MacOS X
-
Download and Install Vagrant Option A (Vagrant)
- a. Create a new folder << vagrant folder >> (such as
ubuntu-docker) cd << vagrant folder >>vagrant init ubuntu/trusty64vi VagrantFile- Pick an IP address for Vagrant (such as 10.88.0.8)
- change line
config.vm.network "private_network", ip: "<< ip address >>" vagrant up
Option B (EC2)
- Or, host of your choice
- a. Create a new folder << vagrant folder >> (such as
-
Install Docker and Dokku
vagrant sshsudo apt-get updatesudo apt-get install dockersudo apt-get install daemontoolssudo apt-get install build-essentialsudo apt-get install libtool- Install dokku: (needed to run it twice last time, maybe a transient problem)
- wget -qO- https://raw.github.com/progrium/dokku/v0.3.12/bootstrap.sh | sudo DOKKU_TAG=v0.3.12 bash
- Update build-step
- git clone https://github.com/progrium/buildstep.git
- cd buildstep
- git pull origin master
- sudo make build
- (reference: http://progrium.viewdocs.io/dokku/upgrading)
- Increase swap space: http://stackoverflow.com/a/22247782/1022903 (for non-Vagrant usage)
-
Config host machine
- Exit vagrant ssh shell
- Edit
/etc/hoststo add line:- << ip address >> dokku.me
-
cat ~/.ssh/id_rsa.pub | vagrant ssh dokku.me "sudo sshcommand acl-add dokku $USER"
-
Create a project and push
git remote add dokkudev dokku@dokku.me:<< app name >>git push dokkudev master- For each config:
dokkudev config:set << app name >> ...
- Or, ssh into vagrant
cd << vagrant folder >> && vagrant ssh- And, edit
~dokku/<< app name >>ENVdirectly - ** remember to include
exportin front of each lines -
dokku config:set << app name >> a=b# to cause config reload
- And, edit
dokkudev logs << app name >>- If error arise:
setuidgid: fatal: unable to run failure, do step 2.5 ('daemontools')
-
Install plugins
- log into vagrant
cd /var/etc/lib/dokku/pluginsgit clone https://github.com/dyson/dokku-docker-optionscd /var/etc/libgit clone https://github.com/dokku-alt/dokku-alt.gitcd /var/etc/lib/dokku/pluginsln -s /var/etc/lib/dokku-alt/plugins/dokku-mariadb/dokku plugins:install
-
Update MySQL
FLUSH TABLES WITH READ LOCK; FLUSH LOGS; SET GLOBAL binlog_format = 'MIXED'; FLUSH LOGS; UNLOCK TABLES; # http://dba.stackexchange.com/a/6753