Wiki
Clone wikiSAGE2 / Install (Docker)
Install Instructions for Docker (Windows, Mac OSX and Linux)
revision 2015-02-24
Install Docker
If you have Docker installed jump to "Install SAGE2". Follow the installation instructions for your operating system here
Test Docker
Now verify that the installation has worked by downloading the ubuntu image and launching a container.
#!shell docker run -i -t ubuntu /bin/bash
#!shell exit
Install SAGE2
Get the latest SAGE2 image from dockerhub
#!shell docker pull sage2/master
#!shell docker create -v /sage2/config --name sage2Config sage2/master docker create -v /sage2/keys --name sage2Keys sage2/master docker create -v /root/Documents/SAGE2_Media --name sage2Uploads sage2/master
#!shell docker run --rm -it --volumes-from sage2Keys sage2/master /sage2/keys/GO-docker _.evl.uic.edu
#!shell docker run --rm -it --volumes-from sage2Config sage2/master /bin/bash cd /sage2/config vi docker-cfg.json exit
Running SAGE2
First time you run SAGE2, you need to create a container that specifies how to run SAGE2. With the command below you create the container and run SAGE2.
#!shell docker run -d --volumes-from=sage2Config --volumes-from=sage2Keys --volumes-from=sage2Uploads -p 9090:9090 -p 9292:9292 --name sage2 sage2/master
#!shell docker ps
#!shell docker logs sage2
#!shell docker stop sage2
#!shell docker start sage2
Setting the time
By default the timezone is set to Chicago time. To set the right timezone for your installation, you need to run the follow command while the container is running (For example setting it ot Arizona).
#!shell docker exec -e "CONTAINER_TIMEZONE=US/Arizona" sage2 /sage2/bin/docker_set_timezone.sh
NOTE: The above command is not persistent. Timezone will reset once you stop it. We suggest creating a startup script that first executes the run command (starting sage2 server) and then executes the exec command to set the right timezone.
Updating SAGE2
#!shell docker pull sage2/master
Backing up and restoring your data
Backing up
You only need to backup your sage2Uploads data container.
#!shell docker export --output="sage2Uploads.tar" sage2Uploads
Restoring
#!shell docker import sage2Uploads.tar
Updated