DEV Community

Dan Stockham
Dan Stockham

Posted on

Deploying to Production using Containers but without Kubernetes

What would be the approach to deploy a traditional web application with a SQL database (PostgreSQL) using containers?

I heard that though Docker compose makes deploying more convenient, it's not the best choice due to the lack of scaling. The better option is Kubernetes but there's not enough ramp up time before our deployment and there's also the question of support -- will I know enough to maintain the cluster?

Are there alternatives?

Thanks! :)

Discussion (4)

Collapse
acook8 profile image
Alex Cook

Before I can answer I need to know a little about your situation. Why are you using containers? Will this be on prem or in the cloud. If in the cloud which cloud provider?

Collapse
danstockham profile image
Dan Stockham Author

The reason I went with using containers so that it lowers the amount of configuring of the environment where the application is hosted from. It'll be hosted from a DigitalOcean droplet.

Collapse
acook8 profile image
Alex Cook

I don't know if DigitalOcean has any container specific products that could help, but that is one thing to take a look at. Besides that you have two main options in my opinion. You can use use a container orchestration tool. Kubernetes is the most popular but there are others that don't do quite as much like Apache Mesos, Hashicorp Nomad, or Docker Swarm. If I were you I would give all three a quick try to understand which one you think would work best for you. And while you are at it and you have time I would also try out Kubernetes on DigitalOcean.

The other option you have is to treat your containerized app like a normal application by running the docker container on multiple web servers behind a load balancer. This will probably be the simplest option, but you lose some of the advantages orchestrators have.

Hopefully this is useful!

Collapse
fl0rian profile image
Florian

If you a re familiear with Docker and already have your dev-environment set up in a dockerized way, docker swarm may be an idea for production as it's scalable:
docs.docker.com/engine/swarm/swarm...