Turbo VM 3.33.814 Released

Clients will be automatically updated to the latest version of Turbo VM.

New and Improved

This update includes the following new features and improvements:

  • Streamed images now show their version number on the main Turbo Launcher panel. This makes it easier when using or testing against multiple versions of an application.
  • Turbo Launcher navigation has been improved and includes category and application metadata caching.
  • The Turbo Launcher login dialog title branding has been clarified.
  • The turbo continue command now supports the --isolate flag.

Bug Fixes

This update includes fixes for the following issues:

  • Chrome extension can crash when uploading a file to a web site
  • Error when performing commit on Windows 7
  • IOException error when using Turbo with Vagrant
  • Incorrect (older) version of Sandbox Manager may sometimes start on systems with earlier versions of Spoon
  • Turbo Launcher may not pull latest version of an image if another image is already cached locally
  • Expired authentication ticket can cause turbo build command to fail
  • Turbo Launcher can start new containers rather than continue existing sessions from recents list
  • Incorrect VM version can be displayed when starting a container
  • Second run of a container with the --config flag can fail
  • Incorrect upgrade message can appear when launching a GUI application
  • copyi command can fail with an empty error message

 

App Virtualization Smackdown: Blow-by-Blow

Microsoft MVP Rory Monaghan provides a detailed review of the new Turbo VM. His conclusion:

Turbo provides the widest variety in terms of packaging options and deployment options. They cater to the widest audience. Their packaging tool is the best of all of the products mentioned in this blog post.

Creating Online SQL Test Lab Environments

Turbo.net is a great way to provide online learning and test lab environments for SQL Server and other complex applications. Turbo VMs provide the user with a ready-to-use database server, sample content, and test IDE environment — without requiring any setup or modifying the host desktop.

This blog post will show you how to create a SQL Server Turbo VM lab that can be embedded directly in a web page or blog post. In our example, we will create a lab environment for this article from SQL Server Central, one of the world’s largest SQL Server communities: http://www.sqlservercentral.com/articles/T-SQL/130558/.

Prerequisites

If you want to follow along building this example, you will first need to download the Wildcard Searches.sql file: Wildcard Searches.sql

The Basics

Our SQL environment will consist of two Turbo VM images:

  1. sqlserver/mssql2014-labsuite, which includes SQL Server 2014 Express and SQL Server Management Studio 2014; and
  2. A content layer that will provide content specific to the article for which the image is being created. Typically this is a SQL script, but could also include a database or other resources.

In this walkthrough the sqlserver/mssql2014-labsuite will be referred to as the “base” image. The base image is available on the Turbo.net Hub and is streamed for fast launch.

Step 1: Create the Lab Image

Specify a Sample SQL Script

Create a folder on your system for the contents of the content layer and change the directory of the command window to that folder.

> mkdir %UserProfile%\Desktop\article-content
> cd %UserProfile%\Desktop\article-content

Copy the Wildcard Searches.sql file into the article-content folder. The SQL Script must be named script.sql.

When SSMS starts, the Object Explorer will not automatically be connected to the Database Server. To avoid confusion for the user, edit the SQL Script and add the following text at the top.

--------------------------------------------------------------------
-- Press Alt+F8 to connect Object Explorer to the current server. --
--------------------------------------------------------------------

Create a turbo.me file which will be used to build the image. If prompted, select to save or create the file.

> notepad turbo.me

Add the following content to the turbo.me file:

### This TurboScript creates a content image to use with
### sqlserver/mssql2014-labsuite.

# Copy the content from the TurboScript directory.
copy "script.sql" "C:\sql-content\script.sql"

We will be using the tempdb which is in our SQL 2014 Express container, so we can skip to Build the Custom Image. If you want to use a custom database as sample content, follow the instructions in the Adding a Sample Database to the Custom Image section.

Adding a Sample Database to the Custom Image (optional, not required for this example)

To use your own sample database, create a new container on top of the base image using the following command. In this example, the container created is named content-for-article.

> turbo new --name=content-for-article --route-block=tcp sqlserver/mssql2014-labsuite

After SSMS launches, configure the sample database.

Or, if you want to restore it from a backup file, use the mount option to specify the folder on the host system where the backup database file resides. In this example, the mount point is set to the folder C:\SampleDB in our new container named content-for-article.

> turbo new --name=content-for-article --mount=C:\SampleDB --route-block=tcp sqlserver/mssql2014-labsuite

After SSMS launches, configure the sample database by restoring the .bak file

When configuration is complete, close SSMS and the content will be saved into the content-for-article container.

Copy the SQL DATA folder from the stopped container content-for-article to the host folder with the turbo.me file and the script.sql file.

> turbo copy content-for-article:"C:\Program Files (x86)\Microsoft SQL Server\MSSQL12.SQLEXPRESS\MSSQL\DATA" host:.

Remove the files that are not needed.

> erase DATA\model.mdf DATA\modellog.ldf DATA\MSDBData.mdf DATA\MSDBLog.ldf DATA\tempdb.mdf DATA\templog.ldf

Once the data is copied out of the content-for-article container, it may be discarded.

> turbo rm content-for-article

Now that the sample database is present, append a line to the turbo.me file to copy the DATA folder into the custom image during the image build process.

### This TurboScript creates a content image to use with
### sqlserver/mssql2014-labsuite.

# Copy the content from the TurboScript directory.
copy "script.sql" "C:\sql-content\script.sql"
copy "DATA" "C:\sql-content\"

Build the Lab Image

Now that we have the contents ready for the lab image, we can build the image using the turbo.me file. Use an appropriate name in place of sql-sample-content. For example, if the VM corresponds to an article, a good practice would be for the image name to match the article title. Our example is based on an article titled SQL Wildcard Searches so we will name our image privatehub/sql-wildcard-searches.

The placeholder privatehub should be set to your login name. (You can find your login name with the command turbo login.)

> turbo build --name=privatehub/sql-wildcard-searches turbo.me

After the build completes, test the new image. Do not remove the test container as it will be used later.

> turbo run --route-block=tcp --name=testing-for-article privatehub/sql-wildcard-searches,sqlserver/mssql2014-labsuite

Publish the Custom Image

Once the image has been tested, push the sql-wildcard-searches image to your privatehub on Turbo.net.

> turbo push privatehub/sql-wildcard-searches

Step 2: Create a Splash Image

The splash image is a screenshot of the VM that is displayed on the application home page and embed view.

You can quickly create the splash image by recording a short demo using the turbo profile command. In our example, we will simply capture a screencast of SSMS with our script loaded.

To prepare an image for profiling, we first have to commit the testing-for-article container we created previously to an image named sqlsample-demo. (Profiling, unlike  regular launches, only works on a single VM image.) Then we run turbo profile with the screencast parameter and the path to the screencast file.

The command below will record the screencast in GIF format. Recording will start 30 seconds from launch and last 10 seconds. The 30 seconds provides you with enough time to exit full screen mode, adjust the SSMS windows to a setup of your choice, and show the sample SQL scripts.

> turbo commit testing-for-article sqlsample-demo
> turbo profile sqlsample-demo transcript-folder --isolate=full --thumbnail --screencast=splashscreen.gif --screencast-format=gif --screencast-start=00:00:30 --screencast-duration=00:00:10

Once you are happy with the screencast, the testing-for-article container and the testing-for-article image for profiling may be discarded.

> turbo rmi sqlsample-demo
> turbo rm testing-for-article

Step 3: Set the Application Name and other Content

Now go to your image’s page on the Turbo.net Hub at https://turbo.net/hub/privatehub/sql-sample-content (Again, private hub is replaced with your login name.)

Set the icon to https://blog.turbo.net/wp-content/uploads/2015/11/sql-icon.png by clicking Edit on the image next to the title.

If the image visibility is Private, set it to Public.

Go to the Settings tab and set the following fields:

  • Splash Image: Upload the GIF we created in the previous section
  • Background Image: Use https://blog.turbo.net/wp-content/uploads/2015/11/sql-background.png
  • Display Name: Wildcard Searches
  • Heading: Wildcard Searches
  • Article URL: The URL of the article the VM is based on
  • Background Color: #052C52 (do not confuse with the Background Image Color)
  • Flags: --route-block=tcp
  • Image Layers: Append ,sqlserver/mssql2014-labsuite to what was already there. The result should look like privatehub/sql-sample-content,sqlserver/mssql2014-labsuite.
  • Set the image to Embeddable.

(If you are using your own sample code, modify the text and graphics as appropriate.)

Press the Run button to confirm that everything is working.

Step 4: Embed the VM into the Article

Your VM can be run from the Turbo.net Hub, but it’s even nicer to embed the VM directly into the corresponding article, blog, or web site.

To embed the VM in an article as shown in the image above, go back to the About tab on the image page, copy the HTML code shown under Share label, and simply paste it into your website!

Turbo Studio 16 Now Available

Turbo Studio is a graphical user environment for creating and editing Turbo VM environments.

The latest version of Turbo Studio includes support for Windows 10, integration with the Turbo container interfaces, support for publishing applications to Turbo.net, and many other new features and improvements.

This update is strongly recommended for users of previous versions of Studio (known as “Spoon Studio”).

What’s New

Release 16 of Turbo Studio includes the following new features and updates:

  • Windows 10 support: Turbo Studio 16 uses the new Turbo VM engine, which includes support for Windows 10. This update is critical for allowing virtualized applications to run on Windows 10 and is therefore strongly recommended for all users of previous versions of Studio (Spoon Studio).
  • Support for Turbo container repositories: Turbo Studio 16 can import and export VM configurations directly from local container repositories. This makes it easy to move between the console-based container and graphical Studio interfaces for creating, viewing, and editing Turbo VM configurations.
  • Publish to Turbo.net: Turbo Studio 16 supports publishing to the new Turbo.net hub. Turbo.net provides thousands of ready-to-use virtual environments and makes it easy to publish and share virtual environments with team members and the web.
  • Architecture merge: Turbo Studio 16 supports dynamic conditional layering based on CPU architecture (x86 or x64). This allows a single Turbo VM image to be deployed that supports both 32- and 64-bit versions of an application. Previous versions of Studio only supported conditional layering based on operating system version.
  • New “Run and Merge” launch mode: The new Run and Merge launch mode launches the application inside a Turbo VM container. Changes to the application configuration during execution are captured and merged back into the active Studio configuration on application shutdown. This enables an easier workflow for configuration changes that can be made within the application interface and does not require manual editing of registry keys or files.
  • Improved environment variable controls: Turbo Studio 16 supports new merge semantics for environment variables. This allows applications requiring specific merge or environment variable override behaviors to work properly on all desktops.

Getting Turbo Studio 16

Turbo Studio 16 is available for download at turbo.net/studio.

The upgrade to Turbo Studio 16 is available for free to all licensed users of previous versions of Studio (previously known as Spoon Studio) on active maintenance.

For commercial users of previous versions, a new license key is available from the account management page of your Turbo.net account.

 

Running Octopus Deploy in Turbo VM Containers

Octopus Deploy is a deployment automation tool designed for .NET developers.

In this blog post we will demonstrate creating a complete Octopus Deploy cluster on a desktop using Turbo VM containers.

To learn more about Octopus Deploy, see the Octopus Deploy website.

The Basics

An Octopus Deploy environment consists of a web server application to manage release activities and a network of Tentacle agents responsible for executing deployment tasks.

We will demo the core features of Octopus Deploy using 4 Turbo containers:

  • An Octopus Server with a SQL Server 2014 database
  • 2 Tentacle clients, to simulate the staging and production environments
  • A web browser used to configure the Octopus Server and trigger deployment

To make things simpler we will run all containers in a virtual network on a single Windows machine. Our deployment project will install Chocolatey Package Manager, a popular package manager for Windows. After successful deployment in the staging environment, we will promote the release to production.

Configure Octopus Server

First, run the Octopus Turbo VM image with the following command. Note this must be done from an elevated privilege command prompt to let Octopus open server sockets and register firewall exceptions.

turbo run octopus/octopus-with-sqlserver --name=server --network=octopus --admin

The image comes with a SQL Server 2014 Express database which is required for Octopus Server.

Click Get Started in the Octopus Manager window to start configuring deploy server.

Provide your contact details to activate the trial or insert a license key and go to the next page. Leave defaults in the Home and Service Account pages.

Fill the Database page using settings below:

  • Server name: \\.\pipe\MSSQL$SQLEXPRESS\sql\query
  • Authentication: SQL Server Authentication
  • Login: sa
  • Password: password1
  • Database: Octopus

The Octopus database does not exist, so the Setup Wizard may display a dialog asking whether to create it. Click OK and go to the next page in the wizard.

Leave defaults in the Web Portal page. Don’t worry if port 80 is already in use on your machine since Octopus is running in a virtual network.

Set up your login credentials to Octopus Server, which will be used to access the Deployment Portal. Then go to the Install page.

Uncheck Automatically check for new updates option and start the installation process. After a successful setup process you should see the Octopus Manager window showing  the Octopus Server is ready to use.

Octopus_Server_ReadyToUse

Next we need to login to the Deployment Portal. To do this, run Firefox in a container connected to the virtual network and go to http://server:80 (or a different host name if you didn’t use the name server for the server container):

turbo run mozilla/firefox --name=browser --network=octopus http://server:80

Login to the Octopus Deployment Portal using the credentials provided in the Setup Wizard.

You should see an empty dashboard page. We are now ready to setup our Tentacle agents!

Configure Tentacle Clients

We repeat the process to launch the Tentacle clients, except this time we run the octopus/tentacle Turbo image. Again, this should be done from an elevated command prompt to let Tentacle open a server socket and register firewall exceptions.

turbo run octopus/tentacle --name=staging --network=octopus --admin

Click Get started in the Tentacle Manager window to start the Configuration Wizard.

Go through the wizard using the default settings on the Storage and Communication pages.

Return to the Octopus Deployment Portal to get the Octopus thumbprint from the Listening Tentacle page. Then create a new Environment with the Tentacle container as a deployment target.

Select the Environments tab and click Add environment. Set Staging as the name of environment, save the form, and click Add deployment target. Scroll down to the bottom of the page and copy the thumbprint.

Go back to the Tentacle setup wizard, paste the thumbprint, then move to the Install page to start installation.

Once the process completes, return to the Octopus Deployment Portal, set staging in the Hostname field and click the Discover button. The page should change to Deployment Target settings.

Set Display name to Staging, assign a Demo Client role and save the form.

You may want to run the Check Deployment Target health task to ensure the staging environment is sound.

Octopus_Server_HealthCheck

We have finished configuration of the staging environment.

Now repeat steps in this section to create the production environment. The process is the same except we use production instead of staging to name the container and add it to a separate Octopus environment called Production.

Create the Deployment Project

Go to Projects tab in the Octopus Deployment Portal and click Add project. Set Demo Project in the Name field and press Save. The page should change to Demo Project settings.

Select the Process tab, click Add step, and select the Run a Script option.

Octopus_Server_Deployments

Enter Install Chocolatey as the step name and assign a Demo Client role.

Past the code snipped below to the PowerShell template:

(iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1')))>$null 2>&1

Save the form and define a new release by clicking Create release. Create the release using default values for other settings.

Deploy the Project

First we will test our configuration by deploying the project to the staging environment. Click Deploy to Staging, then Deploy Now, and wait a few seconds for the process to complete. The project should be deployed successfully.

If you look at the logs from the deployment process, you may notice the Chocolatey installer printed some warnings suggesting to restart the shell before using it. These can be safely ignored.

Finally, deploy the release to production by pressing Promote to Production!

Good Work!

You’ve successfully deployed and configured your Octopus Deploy cluster!

Turbo VM makes it much easier to build and test automated deployments with Octopus Deploy.

If you have any questions or suggestions on this article, please tweet to us at @turbohq or email us at support@turbo.net.