Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save programmerShinobi/2ac4b8678398d3281955fac4950756f6 to your computer and use it in GitHub Desktop.
Save programmerShinobi/2ac4b8678398d3281955fac4950756f6 to your computer and use it in GitHub Desktop.
Deployment Manual Instructions for Updating an Application or Service (ahi-backend) from Version 1.2.32 to Version 1.2.33 Using Docker

Instructions for deploying the ahi-backend version 1.2.33 using Docker

Steps

  1. Navigate to the project directory:

    cd workspace/ahi-backend/
  2. Check the active Git branch: Ensure you’re on the master branch.

    git branch
    • The output should indicate that the master branch is active.
  3. Pull the latest changes from the master branch:

    git pull origin master
  4. Rebuild the Docker image:

    • Build a new Docker image for ahi-backend version 1.2.33 using the alpine.Dockerfile.
    docker build -f alpine.Dockerfile -t gmfdev24/ahi-backend:1.2.33 .
  5. Navigate to the Docker configuration directory for ahi-backend:

    cd server-docker-config/ahi-backend/
  6. Edit the docker-compose.yml file:

    • Open the docker-compose.yml file using a text editor like nano.
    nano docker-compose.yml
    • Locate the line specifying the image version, and update it from:
      image: gmfdev24/ahi-backend:1.2.32
      to:
      image: gmfdev24/ahi-backend:1.2.33
  7. Check the running Docker containers:

    • Find the currently running ahi-backend container.
    docker ps -a | grep ahi
    • Note the CONTAINER ID for the container running version 1.2.32.
  8. Stop and remove the old container:

    • Replace ae34cec1FPM with the CONTAINER ID of the old container if different.
    docker stop ae34cec1FPM && docker rm ae34cec1FPM
  9. Re-run docker-compose with the new image:

    • Use --force-recreate to ensure the container is updated.
    docker compose up -d --force-recreate

After these steps, the deployment of version 1.2.33 should be complete, and ahi-backend will be running with the updated image.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment