Skip to content
This repository was archived by the owner on May 11, 2026. It is now read-only.

iwatkot/maps4fsupgrader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Maps4FS Maps4FS Maps4FS PYDTMDL PYGDMDL
Maps4FS API Maps4FS UI Maps4FS Data Maps4FS ChromaDocs
Maps4FS Upgrader Maps4FS Stats Maps4FS Bot Maps4FS Locale

Maps4FS Upgrader

🔄 Automated Docker Container Upgrader for Maps4FS Deployment

A lightweight Docker container that automatically upgrades your Maps4FS deployment by pulling the latest images and redeploying containers

Overview

The Maps4FS Upgrader is a containerized tool designed to simplify the upgrade process of your Maps4FS deployment. It automatically:

  • 🛑 Stops running Maps4FS containers
  • 🗑️ Removes old containers and images
  • 📥 Pulls the latest Docker images
  • 🚀 Redeploys containers with updated configurations
  • ⏱️ Handles proper startup sequencing

Supported Containers

The upgrader manages the following Maps4FS containers:

  • maps4fsapi - The core API service
  • maps4fsui - The web user interface

Prerequisites

  • Docker installed and running
  • Existing Maps4FS deployment with containers named maps4fsapi and maps4fsui
  • Access to Docker socket (/var/run/docker.sock)
  • USERPROFILE environment variable set (for volume mounting)

Usage

Quick Upgrade

Run the upgrader with a single command:

docker run --rm \
  -v /var/run/docker.sock:/var/run/docker.sock \
  -e USERPROFILE="$HOME" \
  iwatkot/maps4fsupgrader

Windows PowerShell

docker run --rm -v /var/run/docker.sock:/var/run/docker.sock -e USERPROFILE="$env:USERPROFILE" iwatkot/maps4fsupgrader

What Happens During Upgrade

  1. Connects to Docker daemon
  2. Stops maps4fsapi container
  3. Removes maps4fsapi container and image
  4. Pulls latest maps4fsapi image
  5. Deploys new maps4fsapi container
  6. Waits 10 seconds for API to start
  7. Repeats steps 2-5 for maps4fsui container
  8. Completes with success confirmation

Configuration

The upgrader uses predefined container configurations that match the standard Maps4FS deployment:

Maps4FS API Container

  • Image: iwatkot/maps4fsapi
  • Port: 8000:8000
  • Volumes: Maps4FS data directories + Docker socket
  • Restart Policy: unless-stopped

Maps4FS UI Container

  • Image: iwatkot/maps4fsui
  • Port: 3000:3000
  • Volumes: Maps4FS data directories + Docker socket
  • Restart Policy: unless-stopped

Directory Structure

Expected Maps4FS directory structure:

$USERPROFILE/maps4fs/
├── mfsrootdir/     # Generated maps data
├── templates/      # Map templates
└── defaults/       # Default configurations

Logging

The upgrader provides detailed logging for each step:

  • Container status checks
  • Image pulling progress
  • Deployment confirmations
  • Error handling and troubleshooting

Error Handling

The upgrader includes robust error handling for:

  • Docker daemon connection issues
  • Missing containers or images
  • Volume mounting problems
  • Network connectivity issues

Development

Local Development

  1. Clone the repository:
git clone https://github.com/iwatkot/maps4fsupgrader.git
cd maps4fsupgrader
  1. Install dependencies:
pip install -r requirements.txt
  1. Run locally:
python maps4fsupgrader/main.py

About

A lightweight Docker container that automatically upgrades your Maps4FS deployment by pulling the latest images and redeploying containers

Topics

Resources

License

Stars

Watchers

Forks

Contributors