Running Toolbelt in different environments
How to install and run Cloud 66 Toolbelt on a server or inside a Docker container
Installing on a server (headless)
To install Toolbelt on a server (without a browser):
- Install and authenticate 
cxon your local machine (see above) - Log into your server via your terminal and move to the 
.cloud66directory (underhome) - Create a file named 
cx.jsonin that folder - Go to the terminal on your local machine, where you already have Toolbelt authorised and execute 
cx dump-token, which will give you your authorisation token - Copy this token and paste it into the (remote) 
cx.jsonfile that you created in Step 3 - Save the file and then run 
cx stacks liston the server to confirm that Toolbelt is initialised 
Running Toolbelt inside a Docker container
You can run the Cloud 66 Toolbelt inside a Docker container, although this is not officially supported.
Step 1: Start an ubuntu container
We start a generic Ubuntu container (Cloud 66 runs on Ubuntu servers)
Step 2: Install required/useful tools
Toolbelt relies on three tools - curl, nano and ssh - so we install these packages.
Step 3: Create some default folders
We need to create some default folders to support Toolbelt’s requirements.
Step 4: Install Toolbelt
Now we install the Toolbelt by CURLing the installation shell script on S3:
Step 5: Register Toolbelt
Finally, we need to register Toolbelt:
- Install and authenticate 
cxon your local machine - SSH into your container and move to the 
.cloud66directory (underhome) - Create a file named 
cx.jsonin that folder - Go to the terminal on your local machine, where you already have Toolbelt authorised and execute 
cx dump-token, which will give you your authorisation token - Copy this token and paste it into the (container’s) 
cx.jsonfile that you created in Step 3 - Save the file and then run 
cx stacks listfrom inside the container to confirm that Toolbelt is initialised 
After this, you should be able to use cx commands inside the container.