This Docker image will allow us to run the amazing Sublime Text 3 without the need to install it in our computers.
Another benefit is to be able to try different Sublime Text builds, with different Programming Languages versions.
The motivation to create this package come from the burn of reinstalling my Development environment across several computers each time I install/upgrade an OS or change computer.
So this package is the first of a series of other packages to make my Development environment very portable, easy and fast to install in any computer.
The recommend way is to build the image locally with bash interface sublime
. See instructions here.
This will map the current folder in the HOST to folder developer
inside the Container.
$ curl -OL https://gitlab.com/exadra37-docker/sublime-text-3/raw/master/src/docker-hub.sh && chmod ug+x docker-hub.sh
$ ./docker-hub.sh
NOTE: The preferable method is to use the Sublime Docker CLI to build the image locally and run it.
bash -c "$(curl -fsSL https://gitlab.com/exadra37-docker/sublime-text-3/raw/master/setup/install)"
bash -c "$(wget https://gitlab.com/exadra37-docker/sublime-text-3/raw/master/setup/install -O -)"
By default the Sublime Text build is 3126
and the Sublime Text will persist settings, cache and installed packages in
dir /home/$USER/.docker-sublime
.
The default Host dir shared with the Sublime Text Container is /home/$USER/Developer
, that we can override at any time.
sublime
Check how to use it at any time...
sublime -h
Currently the Sublime Text build defaults to 3126
.
We can build the Docker Image with a previous or future build of Sublime Text, just by providing a different build number...
sublime -b 3124
By default /home/$USER/Developer/Workspace
on Host is mapped to Container /home/$USER/Developer
, but we can change the path
in the Host we want to map into the Container, like:
sublime -d /absolute/path/in/host
To have the Ubuntu inside the Docker Image up to date we should rebuild the image every week.
sublime -r
For trouble shouting Sublime Text 3 installation we may need to go inside the docker container.
To help us on that, when starting the container the exact command will be printed:
sudo docker exec -it ST3_1486504665 bash