Tagged: Docker

Docker for Mac debugging

The Problem:

While trying to setup Docker for Mac I kept getting the following error anytime I tried to spin up a Docker image:
Couldn't connect to Docker daemon. You might need to start Docker for Mac.

All the fixes said do this:

eval "docker-machine env default"

I tried but kept getting

Host does not exist: "default"

The fix for me

I had to run this:

docker-machine create --driver virtualbox default

and then this:

eval "docker-machine env default"

Also, anytime you open a new terminal you'll have to run

eval "docker-machine env default"

Continue Reading →

Heroku Database Limits

I've been using Heroku for years and it is a great service with great support. Our company, AtomicJolt uses it for all new projects since we an quickly bring up a new site on a free account and show it to our customers.

One problem we frequently run into is the database row limit when using the development plan. Once you hit 10,000 rows your database write permissions are turned off and you will start to see this error:

PG::Error: ERROR: permission denied for relation [table name here]

At that point you have a couple of options:

  1. Upgrade your database to a paid plan (which can get expensive fast).
  2. Reduce your rows to under 10k by deleting records. Then email [email protected] and as them to give you back permissions. They are really nice about it and fast to respond.
  3. Try out a different host. It's a bit more work but we're also loving Digital Ocean. They support Docker which makes deployment really simple.

Continue Reading →

Secure ElasticSearch behind Nginx using Docker on Digital Ocean

I've been a big fan of Elastic Search for a very long time. It's a great piece of software that can be used as an object database as well as a search index. I realize that's not the intention of the software but it works so I'm happy. Elastic Search doesn't have security built in so if you want to lock down your index (which is a good idea) then you'll need to run it behind a proxy. I briefly considered writing something in Go. There's a node.js proxy for Elastic Search but it hasn't been maintained in quite some time.

I want fewer moving pieces. Nginx provides basic authentication. I'm happy with that.

Digital Ocean is a new(ish) hosting company. They run on SSDs. They are pretty cheap and you can have a server running Docker in 55 seconds. I'm happy with that.

Mix all the above and you get a nice bit of software that you can be happy with after you figure out the mixing part. It goes something like this:

###Start Setup an account on Digital Oce...

Continue Reading →