Skip to main content

Test your website in IE using Linux with Vagrant/Virtualbox

I've had an on-off relationship with Vagrant, having first used it for a short while at a previous job. However, in my current employment, we primarily use Linux based laptops, while a select number use Macs. Either way, testing our website developments in Internet Explorer is an added, but necessary headache.

However, Vagrant is actually quite brilliant for not only hosting development environments with ease, but for also hosting flavours of Windows, all with their different combinations of Internet Explorer. I remember back in 2010, using the likes of IETester to install multiple versions of IE within Windows. It was messy and unreliable.

Back to 2016, Vagrant works with Virtualbox to bring you multiple virtual machines that allow you to test your work easily.

I'll skip over installation of Vagrant and Virtualbox. Just visit their respective websites, and install as required.

If you're intention is only to test one version of IE, you could simply visit and download a suitable box to your machine. Or, you could use this gist to grab all of the vms. This link contains a Vagrantfile to save into a given folder on your machine. I've set up a folder called windowsvms, and saved the Vagrantfile there.

I then access my terminal, and cd windowsvms, then type the following:

IE=Win7IE8 vagrant up

Assuming you have a decent internet connection, the box will get downloaded and unpacked to this location. Once everything has completed, Virtualbox will appear to boot your new virtual machine.

By default, you can browse the internet in your guest VM. However, you need to find out how to access your website running on the host. Assuming you have a site running on localhost, on Linux you can use the ifconfig command to get details of your host ip address.

Type ifconfig, and look for the inet addr under usually wlan0 (for wireless connection) – it will look like You can test this by going to your web browser, and replacing 'localhost' part of the address with the ip address. You should still get your website.

Now, check your network connection in the Virtualbox menu. Look under Devices > Network > Network Settings. You should have only one adapter active. If not, then ensure it is enabled and set to NAT, with Cable Connected. Close the window, go to the Start menu, and type cmd, to bring up the command prompt.

We now need to find out the gateway ip address so we can view the website in IE. Type ipconfig, and look up the details for something like Ethernet adapter Local Area Connection 1. Find the IP address under the default gateway, it should resemble or similar. This is the address we need.

Now open IE in your guest VM, and input the following URL:

replace website with whatever your address is, and you should now see your website within IE.

Once you get the hang of it, Vagrant and Virtualbox are an ideal set of tools in your armoury of browser testing.


Popular posts from this blog

Using Beebasm for BBC Basic games programming (Mac & Windows)

In August 2021, I released Androidz Redux , a remastered version of my 1994 game Androidz . This process started a year ago, with a couple of days spent playing around with the original code, far away from a real BBC computer. The original game was published in a magazine called Acorn Computing, and has been available to play online for a number of years now. Because I wrote the game on an actual BBC Micro, I used what tools I had at the time, namely some graph paper to create the graphics, and the computer itself to do the actual coding. This is a world away from the tools we now have at our disposal. Fully rounded IDE's such as Visual Studio Code (my current favourite) make it an awful lot easier to program games. Even editors such as Notepad++ offers some ability to edit BBC Basic code. One of the difficulties with editing old games on modern systems is ensuring that you are able to ensure that the BASIC code is properly tokenised before running on an emulator/system, and indee

Building BBC Micro game disc images using Linux

[July 2017 update - links to BBC games updated to HTTPS links] I wrote this following blog post around Christmas 2015, during that time I posted various BBC Micro games running via the JavaScript based jsBeeb emulator onto Facebook. These games were typically buried within compilation discs, so were not easy to access. Although jsBeeb provides an  auto boot  facility, you still had to go through any menus provided on the disc in order to get access to said game. This post details how you can build your own images, via a special tool, available to build on all platforms. The article follows... As it is Christmas, there's no better time to stoke the fires of nostalgia, and take part in some retro gaming. In the past, a fair amount of effort was required to satisfy your desire for playing of games of yesteryear. Thankfully, browser technology and the incredible abilities of the JavaScript language now make it much easier than ever to play old games. The Internet Archi

Rough guide to building UK election maps for D3.js

During my time at CITY A.M. I helped to build an interactive British General Election Map . This blog outlines how I created it. Let's see the map then Here's a simplified version of the map, hosted at Codepen. See the Pen D3 Election Map by Stephen Scott ( @sassquad ) on CodePen . Here, the map looks rather small, as it has been resized to fit the page. You can use your mouse wheel (or double-click/double-tap) to zoom in or out of the map, and click constituencies to view more detailed results on the left hand side. Each constituency is coloured according to party livery. This blog post gives a very general guide as to how that map was created. I'll be adding further detail about the creation of the map in subsequent posts. Acknowledgements This project was the work of several people, in addition to myself. Here are the other former colleagues who collectively made the election map possible: Michael King (back end programming of data capture system) Bill