Deploying Trains Server: Windows 10
Trains is now ClearML
This documentation applies to the legacy Trains versions. For the latest documentation, see ClearML.
For Windows, we recommend launching our pre-built Docker image on a Linux virtual machine (see Deploying Trains Server: Linux or macOS. However, you can launch Trains Server on Windows 10 using Docker Desktop for Windows (see the Docker System Requirements).
Deploying
Securing deployment
By default, Trains Server deploys as an open network. To restrict Trains Server access, follow the instructions in the Network and security section, on the "Configuring Trains Server" page.
To deploy your Trains Server on Windows 10:
-
Install the Docker Desktop for Windows application by either:
- Following the Install Docker Desktop on Windows instructions.
- Running the Docker installation wizard.
-
Increase the memory allocation in Docker Desktop to
4GB
.-
In your Windows notification area (system tray), right click the Docker icon.
-
Click Settings, Advanced, and then set the memory to at least
4096
. -
Click Apply.
-
-
Remove any previous installation of Trains Server.
This clears all existing Trains SDK databases.
rmdir c:\opt\trains /s
-
Create local directories for data and logs. Open PowerShell and execute the following commands:
cd c: mkdir c:\opt\trains\data mkdir c:\opt\trains\logs
-
Save the Trains Server docker-compose YAML file.
curl https://raw.githubusercontent.com/allegroai/trains-server/master/docker-compose-win10.yml -o c:\opt\trains\docker-compose-win10.yml
-
Run
docker-compose
. In PowerShell, execute the following commands:docker-compose -f c:\opt\trains\docker-compose-win10.yml up
Your server is now running on http://localhost:8080.
Port mapping
After deploying Trains Server, the services expose the following node ports:
- Web server on port
8080
- API server on port
8008
- File server on port
8081
Restarting
To restart your Trains Server Docker deployment:
- To restart Trains Server, first stop and then restart the Docker containers by executing the following commands:
docker-compose -f c:\opt\trains\docker-compose-win10.yml down docker-compose -f c:\opt\trains\docker-compose-win10.yml up -d
Upgrading
-
Shut down the docker containers. Execute the following command:
docker-compose -f c:\opt\trains\docker-compose-win10.yml down
-
If you are upgrading Trains Server version 0.15 or older, a data migration is required before you upgrade. First follow these data migration instructions, and then continue this upgrade.
-
We recommend backing up your data and, if your configuration folder is not empty, backing up your configuration.
For example, if your configuration is in
c:\opt\trains
, then backupc:\opt\trains\config
andc:\opt\trains\data
. Before restoring, remove the old artifacts inc:\opt\trains\config
andc:\opt\trains\data
, and then restore. -
Download the latest
docker-compose.yml
file.curl https://raw.githubusercontent.com/allegroai/trains-server/master/docker-compose-win10.yml -o c:\opt\trains\docker-compose-win10.yml
-
Startup Trains Server. This automatically pulls the latest Trains Server build.
docker-compose -f c:\opt\trains\docker-compose-win10.yml pull docker-compose -f c:\opt\trains\docker-compose-win10.yml up -d
If issues arise during your upgrade, see the FAQ page, How do I fix Docker upgrade errors?.