- Use digital ocean image with Dokku pre-installed, set up ssh key through web.
apt full-upgradeto update packages.
dokku apps:create myapp.somedomain.comand add
git remote add dokku dokku@DOKKU_HOSTNAME:myapp.somedomain.com
- I used /etc/hosts to access the image from a hostname instead of IP.
- More detailed setup in the various deploy with dokku guides I was following.
dokku plugin:install https://github.com/dokku/dokku-postgres.git
dokku postgres:create somedatabasename
dokku postgres:link somedatabasename myapp.somedomain.com
dokku git:set --global deploy-branch production
dokku git:set myapp.somedomain.com deploy-branch staging
dokku config:set myapp.somedomain.com MY_ENV_VAR=value
dokku config:unset myapp.somedomain.com MY_ENV_VAR
dokku domains:reportlists domains used per app
dokku apps:listfor a simple list
dokku report myapp.somedomain.comto get some detailed output
docker ps --allto see containers that have been running
dokku run myapp.subdomain.com 'whoami'runs shell commands in a container
Configure with the LetsEncrypt plugin:
dokku plugin:install https://github.com/dokku/dokku-letsencrypt.git
dokku config:set --no-restart myapp.somedomain.com DOKKU_LETSENCRYPT_EMAILemail@example.com
dokku letsencrypt myapp.somedomain.com
dokku letsencrypt:cron-job --addto set up auto-renewal
One thought on “Dokku commands: Heroku like deployment with support for docker”
Sorry to bother you, but I wanted to ask a quick question. Is there room to improve when it comes to your website? I ask because most sites need edits, tweaks, content, logos, SEO, marketing, branding, etc. and that’s why I reached out to you.
My name is James and I go around the internet and test services and digital marketplaces to see if they’re legitimat. When I come across some great one, I let everyone know what I decided to stick with, and that’s exactly why I reached out to you today.
You can see my 2 big winners here: https://webvetted.com
Go through the sites, find some services you like, reach out to a few people if you want to push your website to be even better 🙂