This article is more than 1 year old

Fancy renting your developer environment? Visual Studio goes online

Or you could try Gitpod...

Microsoft is offering cloud-hosted developer environments for those using Visual Studio Code or, in private preview, Visual Studio.

Microsoft introduced something called Visual Studio Online back in 2013, which in 2015 became Visual Studio Team Services and then Azure DevOps, which appears to be steady again after Monday's wobbles.

That 2013 version was not for coding, though. It was for hosted source control, issue tracking, build service and more – essentially a hosted version of the on-premises Team Foundation Service.

Now the company has relaunched Visual Studio Online as something closer to what you might expect, an online coding environment. There are two variants. One is based on Visual Studio Code and works both in the browser and with the Visual Studio Code desktop application. At the remote end there is a Linux virtual machine (VM) with either four cores, 8GB RAM and a 64GB SSD, or for the premium option, eight cores, 16GB RAM and 64GB SSD. This option is now in public preview, as announced at the Ignite event last week.

The other variant uses the full Windows Visual Studio IDE and a Windows VM at the remote end. This option is in private preview. It is more ambitious, partly because of Visual Studio's greater complexity, and partly because of the problem of debugging Windows desktop applications.

These run on the remote machine but appear locally via a service called App Sharing, or possibly App Casting. This capability is part of an upcoming release of Live Share, a service which enables remote developers to collaborate in your editor.

You can also set up your own desktop as a remote environment. This is called self-hosting and is free, except that you need an Azure billing account to connect to your own environment.

Visual Studio Online uses a feature called VS Code Remote Development Extensions. The VS Code UI runs locally, but development services including some extensions run remotely. On Windows you can use this feature to develop using the Windows Subsystem for Linux while still using VS Code on the Windows side. It works in a similar way with VS Online. The main requirement is an internet-accessible Git repository. You can upload files to the remote VM by drag-drop and run and debug web applications by automatic or pre-configured port forwarding, so that you can access the application on localhost.

You can run a web application and connect with localhost for test and debug

You can run a web application and connect with localhost for test and debug

The key question is how to configure the remote environment. The service will attempt to work out the requirements by inspecting the code in the repository using Microsoft's Oryx build system along with VS Code extension detection based on the main programming language used, but you can also use a devcontainer.json file to specify the VS Code extensions required and a list of commands to execute after the environment is created. This can include running shell scripts from your repository.

The most flexible approach is to specify a Docker container, though this currently requires an experimental feature flag. Microsoft has an extensive set of sample containers here. Getting the development environment correctly specified may take some work, but once done it becomes completely portable, ready for use by other developers or in future if you need to return to a project.

This approach, whether or not you use VS Online, also has the benefit of not requiring a developer to load up their machine with support for multiple project types, which can be particularly challenging if you need to work with many different platforms.

The online environment does not support multiple concurrent logins. That said, you can use the Live Share feature to have others work on the code with you.

Billing is calculated according to an opaque system of "Environment units", where an active Standard system consumes 125 units per hour and a Premium system, 242 units. An inactive environment costs 2 units per hour. Each unit costs £0.00269. Microsoft reckons a full-time developer will use 100 hours per month costing £37.46, but depending on how long you spend in meetings and training sessions, that may be understated.

Why not just connect to a developer VM using remote desktop technology, rather than using VS Online?

This can work, but there are a few reasons to prefer the VS Online approach. One is that it encourages you to pre-configure or containerise the environment so you can create and dispose of instances on demand, rather than maintaining a single VM. Second, typing into an editor running locally has less latency – giving you a better experience, especially on slower connections.

Eclipse Theia looks a lot like VS Code and supports remote development with Gitpod

Click to enlarge

If you like the sound of Visual Studio Online, but would rather steer clear of the Microsoft ecosystem, an alternative called Gitpod might be worth a look. You get a workspace based on a configurable Docker image, and use Eclipse Theia editor, a project of the Eclipse Foundation which looks a lot like Visual Studio Code and supports many of its extensions.

"Unlike other 'open-source' projects, projects hosted at an Open-Source Foundation are protected against single-vendor decisions against the interest of the diverse community," says the homepage.

Gitpod workspaces are hosted on a Google Kubernetes service. Gitpod is free for open-source developers, up to 100 hours per month, or $9.00 for 100 hours of non-commercial use, or $39.00 for unlimited use.

Microsoft's VS Online service looks promising, though we encountered a few annoyances in quick tests of the preview, and even at Ignite not all the demos ran smoothly. But conceptually it makes sense, whether it is via this service, or an alternative such as Gitpod, or a self-hosted variant. ®

More about


Send us news

Other stories you might like