Docker Upgrade Broke My App — Here’s How I Fixed It

Docker Upgrade Broke My App 
— Here’s How I Fixed It

I recently upgraded to the latest version of Docker, and suddenly, my app stopped working. When I tried running docker-compose, I got an error saying the command couldn't be found. A quick search revealed that Docker now requires docker compose (with a space) instead of docker-compose.

After fixing that, I rebuilt my application, but when I tried to access it in the browser—nothing. Keep in mind, this app had been running fine before the upgrade! After hours of troubleshooting, I finally checked the Caddy server logs and noticed something odd: no requests were coming through.

That led me to check my Caddy configuration, and I realized the issue—previously, I had used host.docker.internal for the reverse proxy, but after the update, I needed to reference the actual container name instead. Changing the config to this solved the problem:

caddyfileCopyEditapi.mysite.com {
    reverse_proxy node_app:3600 {
        header_up X-Real-IP {remote}
        header_up X-Forwarded-For {remote}
        header_up X-Forwarded-Proto {scheme}
    }
}

hoodaloop.com {
    reverse_proxy vue_app:3700 {
        header_up X-Real-IP {remote}
        header_up X-Forwarded-For {remote}
        header_up X-Forwarded-Proto {scheme}
    }
}

Lesson learned: always check the logs first!