17

I want to run multiple Internet Explorer versions on the same machine using Selenium WebDriver with Docker instead of Virtual Machines. Docker runs on entirely Linux, as far as I know, which would render IE in Docker impossible. I'm only asking because I'm seeing Docker working on Microsoft Azure.

NateW
  • 2,856
  • 5
  • 26
  • 46

5 Answers5

8

Docker does not currently work with Windows based applications. The Docker on Azure is Docker running on Linux VM's in Azure. With the advent of Docker for Windows you would think it would be possible, however IE/Edge does not support headless mode. Microsoft has announced that Edge is switching to chromium which will hopefully, finally, bring headless mode to IE/Edge. Docker will never support a GUI environment, it runs counter to their mission.

GHETTO.CHiLD
  • 3,267
  • 1
  • 22
  • 34
  • 5
    Now, 2 Years later, it would be interesting to see updates on this thread – Clijsters Nov 14 '17 at 13:36
  • I’ll try and update it this week. There have been significant changes such as Docker for Windows, however, it’s a lite version of Windows server so I would have to see what the restrictions are. – GHETTO.CHiLD Nov 14 '17 at 14:10
  • 2
    Is it this week yet? – Ryan Lundy Jun 12 '18 at 07:06
  • 1
    Is it this week yet? – sebagomez Dec 20 '18 at 19:13
  • 1
    It is! Sadly though, the answer is still NO! With the advent of docker for Windows and windows server 16 you would think it possible to run ie/edge headless, but you can’t. Hopefully now that edge is switching to chromium headless edge may be a possibility. Docker for the foreseeable future will never support a GUI mode. – GHETTO.CHiLD Dec 21 '18 at 02:04
  • Have a look guys, not a full proof official solution from MS but a start for dockerizing IE/EDGE https://stackoverflow.com/a/55704955/5449500 – Akshay barahate Apr 17 '19 at 11:47
1

You can install wine, and IE6 or IE7. I guess you would prefer IE 10 or IE11.

Have a look for example at

https://hub.docker.com/r/tianon/wine/

or

https://hub.docker.com/r/jess/wine/,

and according to winehq.org, you can use an outdated browser such as IE7, if you modify the previous Dockerfiles.

Do not forget you will not have all the DLL available with wine.

user2915097
  • 30,758
  • 6
  • 57
  • 59
1

Still there is no official approach to run IE/EDGE inside docker as "No Windows docker images have GUI, so we cannot test IE11, EDGE."

But,We can install virtual-box and make this happen.

This approach adds extra layer of virtualization[Nesting of virtualization] on the top of docker to make the IE/Edge execution happen and I think in near future it may leads to to performance issue for heavy testing.

If Selenium testing is what you are looking for and don't have heavy load , you can give a try to the approach mentioned in the link.

Youtube - Selenium Windows containers in Docker under Linux

Github - Windows Images

Blogpost - selenium-on-windows-docker-revolution

Akshay barahate
  • 649
  • 8
  • 23
1

IE 6/7/8 with selenium server could be used on docker using this image: https://github.com/sormy/docker-oldie

Are Butuv
  • 292
  • 3
  • 10
1

Microsoft have released a new feature called Windows Sandbox as part of Windows 10 1903. I believe that it is designed to fill this specific gap, and does allow for some setup to be done prior to the Sandbox being started up. I'm currently looking into seeing if we can use this approach for our own Selenium testing, but I encourage others to check it out too.

Shafiq Jetha
  • 1,337
  • 16
  • 30