El_Matella's avatar

Development environment on Windows

Hi,

I would like to configure a development environment on windows 10 computers. But I'm having some problem as I usually use a UNIX environment.

What I would like to have:

  • Have composer on my host machine
  • Install vagrant (this works)
  • Use SSH with vagrant and homestead
  • Install PHP for Composer?

So, I tried to install composer, but I needed to have PHP on my machine, so I downloaded a PHP for windows zip file, and their was a problem with the openssl extension.

The fact is, I don't even know what I am doing... What do I need for composer to work? Install PHP on my windows? How do I do that, and how can I make php work in this command line?

Then, I can't use the vagrant ssh because Windows doesn't have any ssh configuration.

So my questions are:

  • What do I need to install exactly on a windows machine to have a cool development environment?
  • Does anyone knows an equivalent to Sequel Pro for Windows? An SQL client that works with vagrant using SSH tunnel

Thanks a lot for your help! Have a nice day :)

0 likes
15 replies
alenabdula's avatar

@El_Matella

I use Vagrant & VirtualBox to run all my server environments.

I use my host machine (Windows 7) for everything else (Node.js, Composer, Etc., build stuff)

I work with WordPress as well and have xampp installed, when installing Composer I just specified path to PHP install c:\xampp\php\php.exe.

Then, I can't use the vagrant ssh because Windows doesn't have any ssh configuration.

This is not true. I use Cmder as shell emulator and SSHing just fine.

Does anyone knows an equivalent to Sequel Pro for Windows? An SQL client that works with vagrant using SSH tunnel

There is:

Hope that helps

1 like
El_Matella's avatar

Hi, thanks for the reply!

I tried to user cmder as well, but it turned out that I wasn't able to use vagrant is it because of the following error:

The provider 'virtualbox' that was requested to back the machine
'default' is reporting that it isn't usable on this system. The
reason is shown below:

Vagrant detected that VirtualBox appears installed on your system,
but calls to detect the version are returning empty. This is often
indicative of installation issues with VirtualBox. Please verify
that VirtualBox is properly installed. As a final verification,
please run the following command manually and verify a version is
outputted:

C:\Program Files\Oracle\VirtualBox\VBoxManage.exe --version

So when I try this command, it fails because of the space in "Program Files", but when I try with this command:

"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" --version
4.3.34r104062

So I don't really know what to do here...

As for the composer, I would have liked not to install a complete Xampp configuration, but I guess that there is no other easy solution..

alenabdula's avatar

Regarding the installation of VirtualBox error... Not sure. It's possibly OS related.

Did you try reinstalling VB? Restart computer as well and try following...

  1. In a folder create file called Vagrantfile, gist/code
  2. In terminal (Cmder) navigate to created folder and type vagrant up this will bring the VirtualBox up and provisioning process will begin
  3. Once completed, you can type vagrant ssh and you'll be inside your VM.
  4. Install apache, nginx, etc...

Hope that helps resolve the above error. I've never had such error so it's hard to advise.

As for the composer, I would have liked not to install a complete Xampp configuration

You don't need to be running xampp to use composer. All I'm saying, I use xampp for WordPress as well so PHP was there already. I never tried installing it directly from http://windows.php.net/download.

Nick385's avatar

@El_Matella

This tutorial covers it all https://www.youtube.com/watch?v=WDU1TYe3zGU

My personal opinion if you dont have a mac, dual boot pc install ubuntu or mint mint is more like windows GUI. The terminal of linux works similar to mac. If you want to develop its a good practice it saves time. The terminal of Windows Cmd works like shit in my eyes. It never hurts to know more than you need to :)

El_Matella's avatar

I just reinstalled my Windows 10 entirely, and did the following step, in this order:

  • Downloaded Cmder, Dezziped Cmder in a folder.
  • Download Virtual Box 5.0.10
  • Install VB
  • Download vagrant
  • Install vagrant 1.7.4
  • System Reboot

And when I start cmder, make a vagrant init and then a vagrant up, I still have the same error, arghhh

And in cmd.exe, I can make a vagrant up, it works, it just doesn't in cmder, how could I fix that? (I need to use vagrant with cmder to use the ssh tool)

Yes VB 5 is out :)

@Nick385 I didn't want to install an other OS than Windows... It should be possible to keep it :)

bashy's avatar

Yeah was just wondering why you were still using 4.3 :)

El_Matella's avatar

@Nick385 thanks for the video, I used Git Bash as the video and it works...

Still doesn't know why it doesn't work with cmder...

Thanks anyway!

istvanzseller's avatar

Dude, forget abut the complicatons.Use laragon which is a self-contained enviroment and the development environement of your choice. You migh to install composer , or ruby if you plan to deploy on openshift(nothing better than free), but keep it simple: laragon, a decent ide that's all. Don't forget to run laragon on admin privileges that way you don't have to do the guesss work about pretty urls. If you have any questions, shoot, we're here to help. Vagrant and homestead is good for mac folks who could install apache and dependencies anyway through homebrew , but as an Acer owner these won't work. Ain't gonna be no possibility to get them to work , you feel me? To be serious, go with this solution and then if something doesn't work, just ask. Cheers!

1 like
lindstrom's avatar

I'm on Win 7 and use Cygwin. You will feel right at home. There is some configuration here and there, but most of that is making sure you have environment varialbes for the binaries you need or they are on your system path. Also, when running cygwin setup, install any native providers you might need from within Cygwin (e.g. sqlite3).

https://www.cygwin.com/

A sane dev environment is completely feasible, but a little painful to config, on Windows.

squigg's avatar

Just don't try and use npm node packaging on Windows - nothing but nightmares for me. I ended up just running LinuxMint in a VM (VMware rather than Virtualbox for performance) and everything has been 100x easier ever since.

lindstrom's avatar

@squigg Truth. Although I have npm running and use it from Cygwin. The key is that node-gyp has a few prerequisites to run on Windows. That said, avoid the headaches. If you use Homestead, you can always npm install from there and avoid installing things like VS Express Desktop 2013, etc. on your Windows machine.

If you insist on using npm directly on Windows, see this: https://github.com/nodejs/node-gyp

Please or to participate in this conversation.