Cool things coming to Web Dev on Windows
Here are some very new things coming to Windows 10 to make non-windows development way betterer.
I have been working on ways of improving or finding the perfect setup to develop non-windows applications on Windows. By that I mean not working with dot NET applications in Visual Studio. I primarily work on WordPress and also recently started developing in Laravel. I also do some development work with AngularJS and love nothing more than a little Ménage à trois between them all.
I did play with Vagrant for a while, using VVV and some modifications I made, along with assistance from others, to create a Vagrant box running on Hyper-V. Worked OK but was clunky and had major permission problems. Everything had to be 777 permissions, for the direct sync between the Vagrant instance and windows folder for everything to be happy and that just causes problems in other places.
For the past year, I have been using a pretty good system of a basic Ubuntu 14.04 LTS in a hyper-v instance running EasyEngine. EasyEngine allows the creation of WordPress entire sites in one line; everything configured and ready to go just log in. Convert the WordPress 5 min install into 5 seconds. Also, get PHP stack trace for errors, built in PHPMyAdmin. You can create PHP, MySQL or simple HTML sites; the list goes on.
This setup is simple(for me), fast and I still use it, but there is a small issue with folder sync, in both directions. I use PHPstorm and configure automatic sync up to the instance through SSH but any change on the case, maybe WP-CLI DB export or plugin update, will only be synced down manually. Not a big deal but I still dream of a clean Osx direct terminal connection.
Don’t say, “Just get a Mac”, I have had one, loved it but I also love being able to build my machine, upgrade any part when I want to and just tinker. I also do some Microsoft work, Office 365, SharePoint and RDS server work so I need to be on a Windows system. Sometimes it is just more cost effective that way.
So here are a couple of new items I have been playing with that will bring my dreams so much closer. **Please Note these are both BETA instances and do have bugs if you decide to go Bleeding edge, carry band-aids and don’t be surprised if you get burned**
- The first is BASH on Ubuntu on Windows. It’s not a VM it’s Ubuntu Linux subsystem running on windows, referred to as WSL. Still in BETA but looking promising, literally open Powershell or CMD and type BASH and you have Linux terminal. Windows drives and folders are accessed through the /mnt folder. You can do almost all of what you would typically want to do in a Ubuntu instance. You can’t run a full server, like NGINX, just yet but I believe they are working on that. I was able to do a complete apt-get update/upgrade etc. I installed composer, then the Laravel installer and installed Laravel. I thought that would as far as I could go but I could run PHP artisan serve and get to the localhost:8000 no problem. Again it is BETA, and it is a little slow, but the team has been working on it extensively at Microsoft as well as the guys from Ubuntu. I think this has massive potential, and it is just cool.
- Docker for Windows Beta. I am very new to docker but it is talked about everywhere and being a Microsoft Server Systems Administrator, I know they are incorporating containers into the next versions of Windows Server as well as their online cloud solution Azure. Formally docker used VirtualBox, similar to Vagrant, but this iteration does use Hyper-V built into Windows 10 (Pro, Enterprise, Education). I recently did a talk at WordCamp Sunshine Coast about using Windows Hyper-V for dev work, and this seems to be crossing a lot of the bridges my other solutions have not been able too. I have just recently setup a Laravel Docker instance, called LaraDock, by following the fantastic guide by @Mahmoud_Zalt at Zalt.me, very well done.
I have some more testing to do, and I still need to test using these implementations with a WordPress development experience, but I think there is potential for both.
If you want to try out the Bash on Ubuntu on Windows, you can follow this helpful guide and feel free to ask questions. I have set this up on several machines now and got it down.
The docker-beta you just sing up for here https://beta.docker.com/, and they send you and acceptance email with a day or two, and you can then download and go hard.
Thanks for making it this far, started as a quick update and turned into a small story, but I hope it helps. Let me know if you have any questions about this material or just Windows in general, love to talk about PC hardware and help people build awesome Windows Dev Environments.