Home

Rebuilding Docker Image

Deploying Updated app.py to Your mikr.us Domain

To make your updated app.py changes visible at your mikr.us domain, you need to rebuild and restart your Docker container so it uses the new code. Follow these steps:

1. Stop and Remove the Old Container

First, stop and remove the running container (replace my-flask-app with your container name if different):

docker stop my-flask-app
docker rm my-flask-app

2. Rebuild the Docker Image

From your project directory (where your updated app.py and Dockerfile are located):

docker build -t flask-hello-world .

3. Run the New Container

Start the container again, mapping the port as before:

docker run -d -p 5000:5000 --name my-flask-app flask-hello-world

4. Verify

Visit your domain (e.g., https://myflaskapp.byst.re) in your browser or use:

curl https://myflaskapp.byst.re

You should now see the updated output from your new app.py.


Summary:
You must rebuild your Docker image and restart the container after changing app.py for updates to appear at your mikr.us domain. This is standard for Dockerized deployments and ensures your live app uses the latest code.


Tags: Docker, Flask, Mikrus