Skip to content

Updating a Docker installation

This section outlines the steps to update your SmartScope installation with Podman/Docker

Warning

The database is no backwards compatible between versions. Please back up the database before updating to have a fallback.

Note

If you initially installed a version older than 0.9.2, first download the new smartscope.sh script as described here

  1. Run the smartscope update command.

    #Choose with version you want to update to: latest or stable
    #Replace VERSION with your choice
    
    ./smartscope.sh update VERSION
    
  2. Restart SmartScope

    ./smartscope.sh restart    
    
  1. (Optional) Back up your database

    Warning

    This step is to protect your data in case the update fails.

    ## REPLACE YYYYMMDD by the current date ##
    sudo podman exec smartscope-db /bin/bash -c 'mysqldump --user=$MYSQL_USER --password=$MYSQL_ROOT_PASSWORD $MYSQL_DATABASE > /var/lib/mysql/YYYYMMDD_dump.sql'
    
  2. Stop SmartScope

    cd /to/Smartscope/directory/
    ./smartscope.sh stop
    
  3. Change version in smartscope.yml

    To update your docker installation open the smartscope.yml file

    vim smartscope.yml
    
    Edit the image line to a new version available in GitHub container repository
    version: "3"
    services:
    smartscope:
    image: ghcr.io/niehs/smartscope:CHANGE_VERSION_NUMBER
    user: ${UID}:${GID}
    volumes: 
        ...
    

  4. Restart smartscope

    ./smartscope.sh start
    

    The login screen should show the new version number