Search Menu

How to develop PHP-based web application on Windows machine

How to programmatically delete a node from Drupal

Dark Light
In this article, I will show you the four options you have to develop web application with your Windows machine

Introduction

PHP is a very popular programming language used to develop web applications. Normally, PHP is used with a database like MySQL or MariaDB and the HTTP server Apache in a Linux environment. Those stacks of technology are often referred to as LAMP (Linux – Apache – MySQL- PHP).

A big challenge for web developers using the Windows operating system is to create an efficient virtual machine that mimics the Linux environment.

The simplest one available for Windows is WAMPSERVER. The advantage of this environment is that it works out of the box, and you can configure all the environment stacks (PHP, Apache, MySQL). The limitation of this environment is that you cannot access its operating system by SSH. This means that you cannot install other components than those by default. Nevertheless, it is the best environment for the beginner.

The other possibility is to use a virtual machine like VirtualBox and install a Linux operating system on it. I particularly prefer Ubuntu servers. With this system, you can access the Linux operating system by SSH and install whatever you want. Moreover, you can use Vagrant(https://www.vagrantup.com/) to automatically provision your virtual machine with the application you want, like PHP and MySQL.

Since Windows 10 version 2004, the operating system provides the Windows Subsystem for Linux also known as WSL. This technology allows you to run Linux-based operating systems natively from your machine. WSL is a great tool to create a virtual machine on Windows. Moreover, you can also use Ansible to provision your machine.

Finally, you can use docker to create your virtual machine. This technology is getting more and more popular among developers. It gives you more control to set up everything.

Conclusion

Finally, I think they all have great advantages and some important inconveniences. The key point you need to access is the performance desired from your machine and your knowledge of DevOps. Docker gives a more fine-tuning configuration, but it is slower than using WSL. The VirtualBox and Vagrant “combo” is my least favourite for Windows because I have faced a lot of problems with the sharing folder system. 

Finally, I think they all have great advantages and some important inconveniences. The key point you need to access is the performance desired from your machine and your knowledge of DevOps. Docker gives a more fine-tuning configuration, but it is slower than using WSL. The VirtualBox and Vagrant “combo” is my least favourite for Windows because I have faced a lot of problems with the sharing folder system. 

Related Posts
Total
0
Share