Follow this guide to upgrade your current Supervisely instance.
First, let's stop Supervisely. To do it, run docker-compose stop
command in the folder with your docker-compose.yml
file.
This step is optional, but highly recommended. To be sure you can always go back to the previous version, copy and save somewhere these two folders:
- Configuration folder: directory where you have your
docker-compose.yml
and.env
files. We usually choose/opt/supervisely
or/supervisely
, but if you have installed Supervisely yourself, this folder can be somewhere else. - Database folder: sometimes your upgrade requires database migration so it's a good idea to backup the db before. Database files are stored in
${DATA_PATH}/db
. Default value is/supervisely/data/db
.
Replace your current docker-compose.yml
file with the one we have sent you.
Usually you don't have to replace your current .env
file. Check that nothing has changed, but if something has, replace it, but do not forget to save the variables like SERVER_ADDRESS
from the previous file.
Run docker-compose up -d
in the folder with the docker-compose.yml
file. This action will have two effects:
- Your current docker services like
api
orweb interface
will be started from the latest version - (optional) New values for configuration may be applied
- (optional)
migrator
service may update your database structure to the latest version
Wait a couple minutes and open Supervisely. Everything should work fine and you can start using the new functionality.
Here is a typical script that does update:
# Switch to your Supervisely folder (docker-compose.yml directory)
cd /opt/supervisely
# Stop Supervisely
docker-compose stop
# Create backup dir
mkdir backup
# Copy database and current configuration to backup dir
cp /supervisely/data/db docker-compose.yml .env backup/
# Replace current configuration with updated
cp ~/Downloads/supervisely-update/docker-compose.yml docker-compose.yml
# Restart docker services to run update
docker-compose up -d
My agent changed its status to WAITING: There are two possible reasons - either agents were disconnected during the update (in this case just wait a couple more minutes), or you forgot to set SERVER_ADDRESS
in .env
.
Nothing works now. How do I go back?: In case of any problems with the new release it's easy to go back to a previous version. Just replace your new configuration files with the previous ones from the backup, do the same with the database folder and hit docker-compose up -d
once again.