Upgrading Trains Server
This page describes the upgrade instructions for Trains Server in the following formats:
- AWS EC2 AMI
- Max OS X
- Windows 10
To upgrade in other formats, see:
To upgrade your Trains Server Docker deployment:
The following upgrade instructions use the Linux OS as an example.
- Shut down the docker containers. Execute the following command:
- We highly recommend backing up your data directory before upgrading.
Data directory backup and restore example commands
If your data directory is /opt/trains, then archive all data into ~/trains_backup.tgz by executing the following command:
Restore from this backup by executing the following commands:
sudo tar czvf ~/trains_backup.tgz /opt/trains/data
sudo rm -R /opt/trains/data sudo tar -xzf ~/trains_backup.tgz -C /opt/trains/data
- Download the latest docker-compose.yml file.
curl https://raw.githubusercontent.com/allegroai/trains-server/master/docker-compose.yml -o docker-compose.yml
- Spin up the docker containers. This automatically pulls the latest Trains Server build.
docker-compose -f docker-compose.yml pull docker-compose -f docker-compose.yml up
If issues arise during your upgrade, see our FAQ page, How do I fix Docker upgrade errors?.