Automating Desktop Configuration or How to Deliver Linux to Those Who Don't Have One

Hello everyone. At Convergent, where I work, project teams often include several developers: they can be back-end, front-end and / or layout specialists. Projects are most often developed in PHP, which leads to dependencies on various external bodies such as databases, full-text search systems, and others. And there is a big problem here: colleagues who work on Linux, which is the basis of web development, have no problems. Windows users, on the other hand, are getting a headache.





How to solve this problem? We use several options in our company. In this article, I decided to share our developments.





  • Option one. A ready-made set of tools like OSPanel or XAMPP. In most Yii projects that mostly only use MySQL, these are very good solutions.





  • The second option is Docker. It's great for automating deployments, including legacy projects. But this needs to be taken care of. Now, with the release of WSL 2, working with Docker on Windows 10 (including Home Edition) has become much more convenient than before. There are many articles about this on HabrΓ©.





  • The third option is to put Linux on a second system. This is a rather daunting process, so I automated it using the virtualization and automation tools VirtualBox, Vagrant and Ansible.





GitHub . :





  • Ubuntu 20.04 . , , Ubuntu, .





  • Ansible (Git, Ansible, NVM, PHP, MC, Docker, Docker Compose, PhpStorm, Visual Code, DBeaver Community Edition). Ansible.





VirtualBox Vagrant. β€” . BIOS/UEFI, - (, VT).





PowerShell Git :





git clone https://github.com/s-mokrushin/ubuntu-development-box
cd ubuntu-development-box
cp .env.example .env
      
      



β€” .env . , Ubuntu 16 .





  • BOX_CPU_COUNT β€” . = / 2. β€” 4. β€” 1.





  • BOX_MEMORY_SIZE β€” . = / 2. β€” 8096. β€” 2048.





  • BOX_DISK_SIZE β€” . β€” 75GB. , ( 12 ).





  • BOX_IP_ADDRESS β€” IP- . .





  • BOX_HOSTNAME β€” . .





. . Git, SSH, id_rsa. Ansible /home/vagrant/.ssh.





:





vagrant up
      
      



Vagrant , vagrant up . . , .





Ubuntu 20.04
Ubuntu 20.04

Ansible, vagrant provision ( vagrant up β€” provision, ).





Ansible. , β€œ Ansible, 3 .” β€œ Ansible”. .





Linux , Windows 10. , , , Ansible Vagrant , .





, . - , .





  • OSPanel β€” - Windows ( MongoDB, Redis . .).





  • XAMPP β€” Apache + MariaDB + PHP + Perl Windows.





  • Ansible is a configuration management system.





  • VirtualBox is the most popular operating system virtualization system for workstations.





  • Vagrant is a tool for configuring a virtual environment.








All Articles