Is Docker generally solid enough for production deployment?

Hey,

This is an offtopic question.

We’re packaging and distributing a web application and we feel the need to change the deb/rpm deployment to container way in order to control dependency versions (like a newer Python version on older distros).

I’ve looked around LXC/LXD and sounds tempting for old way of developing application with state stored inside the container. But we also need to deploy to RHEL/CentOS and both LXC and LXD packages state looks deplorable. And doesn’t look like LXD, nor LXC has a future in RHEL world.

I’ve sort of resisted Docker due to various design or security issues it had along the years, but also due the the stateless containers paradigm shift that we, old schoolers, need to embrace.

Is Docker now a reliable platform for small and large production deployments where app uptime is really important?

And what would be some best practices for packaging and distributing apps with Docker?

Since Discourse is exclusively deployed on Docker and I’m sure it has large deployments seems like the best place to ask this question.

Thank you

We are running hundreds of servers over tens of datacenters in both bare metal and cloud, and every part of the Discourse app is ran on Docker containers.

Docker does have it’s fair share of bugs, but for us the benefits outweigh the problems.

Just one thing:

I don’t know exactly what you mean by this, but long term state like a database data, is usually kept in volumes that map to the host.

12 Likes

Are Discourse containers known to run without issues both on hosts with Ubuntu and with RHEL distros (Ubuntu 18.04/16.04 and CentOS 7/8)?

Is this expected from Docker?

Most people use Ubuntu, it is the recommended OS.

We manage a few on-premise deployments on CentOS 7 (by customer request) without any issues.

Relevant parts of the Ansible role:

- name: add docker repository (CentOS)
  get_url:
    url: "https://download.docker.com/linux/centos/docker-ce.repo"
    dest: '/etc/yum.repos.d/docker-ce.repo'
    owner: root
    group: root
    mode: 0644
  when: ansible_distribution == 'CentOS'

- name: install docker
  package:
    name: "{{ item }}"
    state: present
  with_items:
  - docker-ce
  - docker-ce-cli
  - containerd.io

- name: ensure docker is started and enabled at boot
  service:
    name: docker
    state: started
    enabled: yes
5 Likes

We run all our infrastructure on Debian. No RHEL anywhere.

2 Likes