DEV Community

Pacharapol Withayasakpunt
Pacharapol Withayasakpunt

Posted on

4 2

How to deploy STATEFUL container on DigitalOcean

The examples of usage includes,

  • When you want to use MongoDB Atlas beyond free tier limits; or other self-hosted database
  • Self-hosted WordPress
  • Self-hosted stateful docker container, such as Remark42 or Isso.

(I have done all three.)

Actually, it's the answer to this question.

The steps required are

    ports:
      - "80:8080"
      - "443:8443"

    environment:
      - SSL_TYPE=auto
      - SSL_ACME_EMAIL=<YOUR_EMAIL>
      - IMAGE_PROXY_HTTP2HTTPS=true
Enter fullscreen mode Exit fullscreen mode

Don't know if this is just my experience. docker-compose build on DigitalOcean droplet failed due to not enough memory. I have to build on my development machine (macOS), then push to Docker Hub. (Yes, this is my first time pushing to Docker Hub.) For anyone curious, see this gist.

For the time-being, feel free to visit the result of my success. -- https://polv.cc

Heroku

This site is built on Heroku

Join the ranks of developers at Salesforce, Airbase, DEV, and more who deploy their mission critical applications on Heroku. Sign up today and launch your first app!

Get Started

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay