Interactive Debug Console¶
Starting A Debug Console¶
You can start a debug console session from the report page for a session.
You will see a “Debug Console” option in the “Actions” drop-down list near the top of each build report page.
When you click “Debug Console”, you’ll be taken to a special report page. You can have at most one debug console per suite. If you already have a debug console running, you’ll be taken to its page.
How Solano CI Prepares a Debug Environment¶
Each new debug console session starts from the same fresh environment as other sessions. As the debug environment is being prepared, you’ll see familiar status messages indicating progress installing your app in a clean sandbox, building a bundle if necessary, and launching and preparing databases.
Using the Debug Console¶
Once setup is complete, you’ll see an SSH URL which you can use to log in to the debug session’s console. It is also possible to use VNC to connect to the remote display so that you can use a web browser in the debug environment, for instance to watch Selenium tests as they run.
It is very important that you terminate the session when you are done with debug mode, not just log out as the VM is assigned to you and not torn down automatically like a normal session.
You can stop the session at any time by clicking on the stop session link in the session report page. Solano CI by defaults sets a 30 minute idle timeout for interactive sessions; you can extend the timeout from an interactive session report page as well. When a session is timed out, Solano CI will terminate your instance and save a git diff of your changes at the bottom of the session report page.
Click to copy the ssh command, and paste into a terminal. The debug environment will allow login using any of the keys you have authorized with Solano CI (check using the
When you log in via SSH you will have full shell access to the CI environment.
The primary way to interact with the environment other than via the shell is by using the tddsh command:
$ tddsh Tasks: tddsh version # Print the version of tddsh tddsh help [TASK] # Describe a command tddsh tddium:env # Print Solano CI environment tddsh tddium:exec # Run command in Solano CI environment tddsh tddium:ping # Ping Solano CI management daemon tddsh tddium:reset # Reset environment and terminate debug session tddsh tddium:root # Print root of repository in Solano CI environment tddsh tddium:shell # Start shell in Solano CI environment tddsh tddium:suite # Print suite configuration
By default, the interactive environment will start a login shell with the Solano CI environment variables loaded for you so you can simply run commands as you normally would:
$ bundle exec rspec spec/models/user_spec.rb
You can also start a new shell with the environment configured:
$ tddsh tddium:shell
Logs and VNC Access¶
You will find logs in the log directory, and temp files in /tmp/tmp0. You can make changes to code and re-run tests. Debug environments come with a VNC server running on display :0. You can connect to it for Selenium debugging using an ssh tunnel from your workstation:
workstation$ ssh -L 5900:localhost:5900 email@example.com -N workstation$ vncviewer :0
Stopping the Debug Console¶
Debug environments don’t stop on their own (yet). Debug environment usage currently counts towards your account usage, at the rate of 2 workers per hour. This rate will change as beta progresses. Make sure you stop the environment when you are done using it, but collect your changes before you do so – environments can’t be recovered.
$ git diff > /tmp/tmp0/solano.patch workstation$ scp firstname.lastname@example.org:/tmp/tmp0/solano.patch . $ tddsh tddium:reset