<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Gavin Murambadoro</title>
    <description>The latest articles on Forem by Gavin Murambadoro (@gmurambadoro).</description>
    <link>https://forem.com/gmurambadoro</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F244432%2F5d282f9d-65a6-42a9-8edf-2adc583a7c0d.jpeg</url>
      <title>Forem: Gavin Murambadoro</title>
      <link>https://forem.com/gmurambadoro</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/gmurambadoro"/>
    <language>en</language>
    <item>
      <title>Symfony7 Docker Template</title>
      <dc:creator>Gavin Murambadoro</dc:creator>
      <pubDate>Wed, 23 Oct 2024 09:20:27 +0000</pubDate>
      <link>https://forem.com/gmurambadoro/symfony7-docker-template-5066</link>
      <guid>https://forem.com/gmurambadoro/symfony7-docker-template-5066</guid>
      <description>&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fxykos97qor3bt2jk19ur.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fxykos97qor3bt2jk19ur.png" alt="Symfony7 Docker Template" width="763" height="302"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;As a full-stack developer, I love working with PHP and the Symfony framework (more recently Laravel as well).&lt;/p&gt;

&lt;p&gt;One of my pain points in the PHP ecosystem is having to work with different versions of PHP (and its extension combinations). To make this worse, my OCD also makes me disdain having to install PHP natively on my Linux development machine.&lt;/p&gt;

&lt;p&gt;I have come through a long journey of solving this problem over the years, from bare-metal installation to using VirtualBox and Vagrant.&lt;/p&gt;

&lt;p&gt;Containerisation with Docker and Docker-compose has made it easier to spin up development setups for different applications.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://github.com/gmurambadoro/Symfony7-Docker-Template" rel="noopener noreferrer"&gt;Symfony7 Docker Template&lt;/a&gt; is my latest iteration of having a ready to go template that I can easily customize and start building full-stack containerized Symfony applications.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Getting Started&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Go to &lt;a href="https://github.com/new" rel="noopener noreferrer"&gt;https://github.com/new&lt;/a&gt; to create a new project. Make sure you choose Symfony7-Docker-Template under the &lt;em&gt;Repository template&lt;/em&gt; section.&lt;/p&gt;

&lt;p&gt;Fill out the rest of the required fields as requested and then click on &lt;em&gt;Create repository&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhgik7lkbw7rcyc4gjgvj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhgik7lkbw7rcyc4gjgvj.png" alt="Image description" width="800" height="768"&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Your new project will be created and you can check it out on your computer and off you go, developing your full-stack Symfony7 application with ease.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhfhh6gmfctu2yu897o05.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fhfhh6gmfctu2yu897o05.png" alt="Image description" width="800" height="435"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;DevContainers you might say?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Maybe it's a skill issue or &lt;a href="https://cloudomation.com/en/cloudomation-blog/devfile-devcontainer-vs-dockerfile-docker-compose/" rel="noopener noreferrer"&gt;maybe it's too complex for me&lt;/a&gt;. All I need is a starter Symfony7 application with decent packages pre-installed and backed up by a MariaDB database that I can access via a localhost URL.&lt;/p&gt;

&lt;p&gt;Kindly checkout my project and let me know what you think.&lt;/p&gt;

&lt;p&gt;Happy coding 🎉.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>productivity</category>
      <category>docker</category>
      <category>symfony</category>
    </item>
    <item>
      <title>How to start a Symfony 7 application with Docker without having PHP locally installed on your machine</title>
      <dc:creator>Gavin Murambadoro</dc:creator>
      <pubDate>Thu, 16 May 2024 16:46:13 +0000</pubDate>
      <link>https://forem.com/gmurambadoro/how-to-start-a-symfony-7-application-with-docker-without-having-php-locally-installed-on-your-machine-28h2</link>
      <guid>https://forem.com/gmurambadoro/how-to-start-a-symfony-7-application-with-docker-without-having-php-locally-installed-on-your-machine-28h2</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Original Post:&lt;/strong&gt; &lt;a href="https://kumoitech.xyz/blog/how-to-start-a-symfony-7-application-with-docker-without-having-php-locally-installed-on-your-machine"&gt;https://kumoitech.xyz/blog/how-to-start-a-symfony-7-application-with-docker-without-having-php-locally-installed-on-your-machine&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;As a full stack developer, I usually have so many projects that I will be working on. Obviously, each project is different from the other ones in many different ways, for example the underlying language, the database required, the package ecosystems, amongst many other variables.&lt;/p&gt;

&lt;p&gt;To support development of these projects, you often need to install the different runtimes required, for instance, you might need to install and configure multiple versions of PHP, install different database types e.g. MySQL, PostgreSQL or MongoDB, as well as ensure that each project is properly configured to use only the resources it is built for.&lt;/p&gt;

&lt;p&gt;Obviously, this leads to having so much bloat on your poor-old development laptop, which might be a nightmare to set-up again in case you format your machine (which I do most of the time) or get a new one.&lt;/p&gt;

&lt;p&gt;I started using virtualization tools like VirtualBox and Vagrant to create separate virtual development machines for each environment that I needed. This way, I could automatically boot up a virtual machine with PHP7.4+ for projects that needed it, or one with PHP5.6 for the older (legacy) projects. Check out my open source repository &lt;a href="https://github.com/gmurambadoro/lampset"&gt;lampset&lt;/a&gt; on GitHub for an automation script I used to run to do this.&lt;/p&gt;

&lt;p&gt;The downside with virtual machines is that they are very resource intensive, since they are virtually operating systems running on top of you main operating system. For me though, the main reason for looking for alternatives to virtual machines was that the provisioning of my environments after a clean install could take an hour or two after a clean install (remember that I tend to find myself formatting my laptop a lot).&lt;/p&gt;

&lt;h3&gt;
  
  
  And then there was Docker!
&lt;/h3&gt;

&lt;p&gt;Containerization technology especially &lt;a href="https://www.docker.com/"&gt;Docker&lt;/a&gt; started gaining widespread adoption, or at least I started to become aware of it. With containerization, the promise was that it was fast and more optimal in terms of resource utilization. Also, because projects could be packaged as containers, it meant that I no longer needed to share virtualmachines between projects, and each project could declare it's dependencies in a &lt;code&gt;Dockerfile&lt;/code&gt; checked into source code control (&lt;code&gt;git&lt;/code&gt;), saving "future-me" the trouble of figuring out how to run a project six months later.&lt;/p&gt;

&lt;p&gt;Since I work mostly with the &lt;a href="https://symfony.com"&gt;Symfony PHP Framework&lt;/a&gt; in a significant number of my projects, I looked for ways to have run a self-contained Symfony PHP application with all it's dependencies without having to have a locally installed PHP runtime or database.&lt;/p&gt;

&lt;p&gt;This article is a guide on how to run a full stack Symfony application that has a MySQL database backend and phpMyAdmin. This set up is only for local development and dependency declarations, and is not how the application will be packaged and deployed in production.&lt;/p&gt;

&lt;h2&gt;
  
  
  Requirements
&lt;/h2&gt;

&lt;p&gt;You need to have only the following installed on your laptop.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;a href="https://docker.com"&gt;Docker Desktop&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="https://git-scm.com/"&gt;Git Version Control&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Disclaimer:&lt;/strong&gt; I have tested the setup I am describing in this guide on Linux as well as MacOS. I haven't tried it on Windows though (since I do not have a Windows computer) and I cannot vouch for how Docker performs on Windows these days.&lt;/p&gt;

&lt;h2&gt;
  
  
  Getting Started
&lt;/h2&gt;

&lt;p&gt;Please note that all the source code for this guide is available on &lt;a href="https://github.com/gmurambadoro/symfony-lamp-stack-with-docker"&gt;GitHub&lt;/a&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Create a Dockerfile for the Apache2 web server in which Symfony will run
&lt;/h3&gt;

&lt;p&gt;In order to install Symfony 7, my server needs to meet standard PHP requirements as documented &lt;a href="https://symfony.com/doc/current/setup.html"&gt;here&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I am going to use apache2 and PHP8.2 to host and run the application, and as a result I will create a &lt;code&gt;Dockerfile&lt;/code&gt; that uses &lt;a href="https://hub.docker.com/layers/library/php/8.2-apache/images/sha256-5f8cb48977a9542e9edadc05b6ee16e4ae7c03d263d7f083c830399f8f652820?context=explore"&gt;&lt;code&gt;php:8.2-apache&lt;/code&gt;&lt;/a&gt; as a base image.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;FROM php:8.2-apache
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Next, my project will use the directory &lt;code&gt;/var/www/project&lt;/code&gt; as a working directory, so I declare that in the &lt;code&gt;Dockerfile&lt;/code&gt; as well.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;WORKDIR /var/www/project
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;As per Symfony &lt;a href="https://symfony.com/doc/current/setup.html"&gt;requirements&lt;/a&gt;, I ensure that all the required PHP extensions are installed and enabled.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# install php extensions
RUN docker-php-ext-install pdo pdo_mysql bcmath \
    &amp;amp;&amp;amp; docker-php-ext-configure intl &amp;amp;&amp;amp; docker-php-ext-install intl

RUN docker-php-ext-install gd
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;What is a PHP project without &lt;a href="https://getcomposer.com"&gt;Composer&lt;/a&gt;? So let's add that.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# install composer
COPY --from=composer:latest /usr/bin/composer /usr/local/bin/composer
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Next up is installing the &lt;a href="https://symfony.com/download"&gt;Symfony CLI&lt;/a&gt; binary, so that we can have all the goodies that come with it.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# install symfony
RUN curl -1sLf 'https://dl.cloudsmith.io/public/symfony/stable/setup.deb.sh' | bash
RUN apt install symfony-cli -y
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Lastly, let's enable Apache's &lt;code&gt;mode-rewrite&lt;/code&gt; to ensure that URLs are properly written.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# enable apache2 modules
RUN a2enmod rewrite
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Source Code:&lt;/strong&gt; &lt;a href="https://github.com/gmurambadoro/symfony-lamp-stack-with-docker/blob/main/Dockerfile"&gt;https://github.com/gmurambadoro/symfony-lamp-stack-with-docker/blob/main/Dockerfile&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Add the the database and phpMyAdmin service dependencies
&lt;/h3&gt;

&lt;p&gt;Now that the web server has been scripted, let's move on to the database. I will use the following official images:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://registry.hub.docker.com/_/mysql"&gt;mysql&lt;/a&gt; for the database.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://registry.hub.docker.com/_/phpmyadmin"&gt;phpmyadmin&lt;/a&gt; for the database browser.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I do not need to modify any of these images, so I will declare these containers in a &lt;code&gt;docker-compose.yaml&lt;/code&gt; file as below:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;services&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
  &lt;span class="na"&gt;db&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="c1"&gt;# The service name or host to the database&lt;/span&gt;
    &lt;span class="na"&gt;image&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;mysql&lt;/span&gt;
    &lt;span class="na"&gt;restart&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;unless-stopped&lt;/span&gt; &lt;span class="c1"&gt;# ensures that the service automatically runs as soon as Docker starts up&lt;/span&gt;
    &lt;span class="na"&gt;volumes&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s"&gt;mysql_data:/var/lib/mysql&lt;/span&gt; &lt;span class="c1"&gt;# persistent volume to ensure that database changes are retained during container restarts&lt;/span&gt;
    &lt;span class="na"&gt;environment&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="c1"&gt;# I do not normally use root to log in to MySQL&lt;/span&gt;
      &lt;span class="na"&gt;MYSQL_RANDOM_ROOT_PASSWORD&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;yes&lt;/span&gt;
      &lt;span class="na"&gt;MYSQL_USER&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;app_development&lt;/span&gt;
      &lt;span class="na"&gt;MYSQL_PASSWORD&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;password&lt;/span&gt;
      &lt;span class="na"&gt;MYSQL_DATABASE&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;app_db&lt;/span&gt;

  &lt;span class="na"&gt;phpmyadmin&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="na"&gt;image&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;phpmyadmin&lt;/span&gt;
    &lt;span class="na"&gt;restart&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;unless-stopped&lt;/span&gt;
    &lt;span class="na"&gt;ports&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="s"&gt;9981:80"&lt;/span&gt; &lt;span class="c1"&gt;# the service will be available in my browser at http://localhost:9981&lt;/span&gt;
    &lt;span class="na"&gt;depends_on&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s"&gt;db&lt;/span&gt;
    &lt;span class="na"&gt;environment&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
      &lt;span class="na"&gt;PMA_HOST&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;db&lt;/span&gt; &lt;span class="c1"&gt;# must match the service name used for the MySQL database above&lt;/span&gt;
      &lt;span class="na"&gt;PMA_USER&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;app_development&lt;/span&gt; &lt;span class="c1"&gt;# must match the value of MYSQL_USER above&lt;/span&gt;
      &lt;span class="na"&gt;PMA_PASSWORD&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;password&lt;/span&gt; &lt;span class="c1"&gt;# must match the value of MYSQL_PASSWORD above&lt;/span&gt;

&lt;span class="na"&gt;volumes&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
  &lt;span class="na"&gt;mysql_data&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="c1"&gt;# the volume name used in db:volumes above&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Under the &lt;code&gt;services&lt;/code&gt; section, I declared &lt;code&gt;db&lt;/code&gt; as the database server and &lt;code&gt;phpmyadmin&lt;/code&gt; as the &lt;code&gt;phpMyAdmin&lt;/code&gt; application that I will use to connect to the database. When running, this application will be accessible at the URL &lt;a href="http://localhost:9981"&gt;http://localhost:9981&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Whilst we are at it, I will also add a service called &lt;code&gt;app&lt;/code&gt; that will be the Symfony application.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;services&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
    &lt;span class="s"&gt;....&lt;/span&gt;
      &lt;span class="s"&gt;app&lt;/span&gt;&lt;span class="err"&gt;:&lt;/span&gt;
        &lt;span class="na"&gt;build&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
          &lt;span class="na"&gt;context&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;.&lt;/span&gt;
          &lt;span class="na"&gt;dockerfile&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Dockerfile&lt;/span&gt;
        &lt;span class="na"&gt;hostname&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;app&lt;/span&gt;
        &lt;span class="na"&gt;restart&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;unless-stopped&lt;/span&gt;
        &lt;span class="na"&gt;container_name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;symfony-app&lt;/span&gt; &lt;span class="c1"&gt;# A custom name to be used in build scripts&lt;/span&gt;
        &lt;span class="na"&gt;depends_on&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
          &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s"&gt;db&lt;/span&gt; &lt;span class="c1"&gt;# requires the database service to be available&lt;/span&gt;
        &lt;span class="na"&gt;ports&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
          &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="s"&gt;9980:80"&lt;/span&gt; &lt;span class="c1"&gt;# the service will be available in my browser at http://localhost:9980&lt;/span&gt;
        &lt;span class="na"&gt;volumes&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
          &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s"&gt;.:/var/www/project&lt;/span&gt; &lt;span class="c1"&gt;# all files in current directory will also be available in the container, allowing you to update the source code with your IDE&lt;/span&gt;
          &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s"&gt;./000-default.conf:/etc/apache2/sites-available/000-default.conf:ro&lt;/span&gt; &lt;span class="c1"&gt;# Override the default apache vhost file to ensure that the symfony application is served by default&lt;/span&gt;
          &lt;span class="c1"&gt;# the contents of 000-default.conf is obtained from https://symfony.com/doc/current/setup/web_server_configuration.html, with modifications applied to match folder locations&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The above declaration will create an &lt;code&gt;app&lt;/code&gt; service for the web application that will be accessible via port &lt;code&gt;9980&lt;/code&gt; of the host machine. Via a &lt;a href="https://docs.docker.com/storage/bind-mounts/"&gt;bind mount&lt;/a&gt;, the source code of the application will be shared between the container and the host operating system, allowing you to work on the project easily using your favourite IDE (&lt;a href="https://www.jetbrains.com/phpstorm/"&gt;PHPStorm&lt;/a&gt;).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Source Code:&lt;/strong&gt; &lt;a href="https://github.com/gmurambadoro/symfony-lamp-stack-with-docker/blob/main/docker-compose.yaml"&gt;https://github.com/gmurambadoro/symfony-lamp-stack-with-docker/blob/main/docker-compose.yaml&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Build the containers
&lt;/h3&gt;

&lt;p&gt;Because I do not have &lt;code&gt;composer&lt;/code&gt; and &lt;code&gt;php&lt;/code&gt; installed locally on my host operating system, I cannot immediately installed the Symfony framework upon which the application is built. I will have to do that insider of the &lt;code&gt;app&lt;/code&gt; container.&lt;/p&gt;

&lt;p&gt;To build the application, I am going to run &lt;code&gt;docker compose up --build -d&lt;/code&gt;. This will provision the entire application stack as defined in the &lt;code&gt;Dockerfile&lt;/code&gt; and &lt;code&gt;docker-compose.yaml&lt;/code&gt; files. The &lt;code&gt;-d&lt;/code&gt; flag runs the containers in the background when the build process is complete.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; writing image sha256:68cbf6b9d16168456ba737a74778553e7d81b0f48ac5a75d9d91569c89633260                                                                                                                                   0.0s
 &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; &lt;span class="o"&gt;=&amp;gt;&lt;/span&gt; naming to docker.io/library/symfony-lamp-stack-with-docker-app                                                                                                                                                          0.0s
&lt;span class="o"&gt;[&lt;/span&gt;+] Running 3/3
 ✔ Container symfony-lamp-stack-with-docker-db-1          Started                                                                                                                                                              0.2s 
 ✔ Container symfony-app                                  Started                                                                                                                                                              0.5s 
 ✔ Container symfony-lamp-stack-with-docker-phpmyadmin-1  Started  
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  4. Log into the web server container
&lt;/h3&gt;

&lt;p&gt;Now that the containers have been built and are running, if you navigate to &lt;a href="http://localhost:9980"&gt;http://localhost:9980&lt;/a&gt; you will encounter the following error:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;Not Found
The requested URL was not found on this server.

Apache/2.4.59 (Debian) Server at localhost Port 9980
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This is because we haven't installed the Symfony framework yet. In order to install the framework, log in to the &lt;code&gt;app&lt;/code&gt; container using the container's name &lt;code&gt;symfony-app&lt;/code&gt; that we defined in the &lt;code&gt;docker-compose.yaml&lt;/code&gt; file.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker &lt;span class="nb"&gt;exec&lt;/span&gt; &lt;span class="nt"&gt;-it&lt;/span&gt; symfony-app bash
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;This will log you into the container in take you to the workspace folder &lt;code&gt;/var/www/project&lt;/code&gt;. Running the &lt;code&gt;ls&lt;/code&gt; will display the files that are in this folder - these are the same files that are on the host computer as well.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;root@app:/var/www/project# &lt;span class="nb"&gt;ls
&lt;/span&gt;000-default.conf  Dockerfile  LICENSE  README.md  docker-compose.yaml
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  5. Install Symfony 7-stable
&lt;/h3&gt;

&lt;p&gt;Run &lt;code&gt;$ symfony -V&lt;/code&gt; inside the container to make sure that the &lt;code&gt;symfony-cli&lt;/code&gt; is  installed.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;root@app:/var/www/project# symfony &lt;span class="nt"&gt;-V&lt;/span&gt;
Symfony CLI version 5.8.19 &lt;span class="o"&gt;(&lt;/span&gt;c&lt;span class="o"&gt;)&lt;/span&gt; 2021-2024 Fabien Potencier &lt;span class="o"&gt;(&lt;/span&gt;2024-05-10T07:24:31Z - stable&lt;span class="o"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now run the &lt;code&gt;$ symfony new&lt;/code&gt; command to install Symfony. We will install the application into a tmp directory called &lt;code&gt;app&lt;/code&gt;.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;root@app:/var/www/project# symfony new &lt;span class="nt"&gt;--webapp&lt;/span&gt; &lt;span class="nt"&gt;--version&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;stable &lt;span class="nt"&gt;--php&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;8.2 app
&lt;span class="k"&gt;*&lt;/span&gt; Creating a new Symfony 7.0 project with Composer
  &lt;span class="o"&gt;(&lt;/span&gt;running /usr/local/bin/composer create-project symfony/skeleton /var/www/project/app 7.0.&lt;span class="k"&gt;*&lt;/span&gt; &lt;span class="nt"&gt;--no-interaction&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;

 ◒  
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;When the installation is done, we need to manually copy &lt;strong&gt;all&lt;/strong&gt; the files and folders inside the &lt;code&gt;./app&lt;/code&gt; directory to the parent folder, except for the &lt;code&gt;./git&lt;/code&gt; folder. Run the following commands in the terminal:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;cd &lt;/span&gt;app
&lt;span class="nb"&gt;rm&lt;/span&gt; &lt;span class="nt"&gt;-rf&lt;/span&gt; .git
&lt;span class="nb"&gt;mv&lt;/span&gt; &lt;span class="k"&gt;*&lt;/span&gt; ../
&lt;span class="nb"&gt;mv&lt;/span&gt; .env ../
&lt;span class="nb"&gt;mv&lt;/span&gt; .gitignore ../
&lt;span class="nb"&gt;mv&lt;/span&gt; .php-version ../
&lt;span class="nb"&gt;cd&lt;/span&gt; ../
&lt;span class="nb"&gt;rmdir &lt;/span&gt;app
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  6. Run the application
&lt;/h3&gt;

&lt;p&gt;At this stage, Symfony is now installed. If you navigate to &lt;a href="http://localhost:9980"&gt;http://localhost:9980&lt;/a&gt; on your browser, you will see the application running. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ff49ek9vz5trmlinq03a9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ff49ek9vz5trmlinq03a9.png" alt="Image description" width="800" height="502"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  6.1 phpMyAdmin connection errors!
&lt;/h3&gt;

&lt;p&gt;If you navigate to &lt;a href="http://localhost:9981"&gt;http://localhost:9981&lt;/a&gt; you will be able to access the database via &lt;code&gt;phpMyAdmin&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fp0xbet1pzuntumy54m4w.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fp0xbet1pzuntumy54m4w.png" alt="Image description" width="800" height="286"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;To fix this error, add the following line under &lt;code&gt;restart&lt;/code&gt; in the service definition of &lt;code&gt;db&lt;/code&gt; in the &lt;code&gt;docker-compose.yaml&lt;/code&gt; file.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;    &lt;span class="na"&gt;command&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;--default-authentication-plugin=mysql_native_password&lt;/span&gt; &lt;span class="c1"&gt;# Fixes the "mysqli::real_connect(): (HY000/1524): Plugin 'mysql_native_password' is not loaded" error&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3yc2nfuop9tjbdnjids6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F3yc2nfuop9tjbdnjids6.png" alt="Image description" width="800" height="105"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;In the terminal, press &lt;code&gt;Ctrl+D&lt;/code&gt; to exit and go to the host shell, and rebuild the containers:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker compose down &lt;span class="nt"&gt;--volumes&lt;/span&gt;
docker compose up &lt;span class="nt"&gt;--build&lt;/span&gt; &lt;span class="nt"&gt;-d&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; I still encountered issues with connection. To fix this, I have to pin the &lt;code&gt;mysql&lt;/code&gt; image version to &lt;code&gt;mysql:8.0&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2nc46ii65xgpqy7p5uu8.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2nc46ii65xgpqy7p5uu8.png" alt="Image description" width="525" height="115"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I ran the commands &lt;code&gt;docker compose down --volumes &amp;amp;&amp;amp; docker compose up --build -d&lt;/code&gt; again and navigating to &lt;a href="http://localhost:9981"&gt;http://localhost:9981&lt;/a&gt; shows the database admin page.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnc5mln12tl6up76xvh8v.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnc5mln12tl6up76xvh8v.png" alt="Image description" width="800" height="405"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  7. Install packages using composer as you need them
&lt;/h3&gt;

&lt;p&gt;Lastly, let's install standard Symfony web application packages. You have to log back into the container.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt; docker &lt;span class="nb"&gt;exec&lt;/span&gt; &lt;span class="nt"&gt;-it&lt;/span&gt; symfony-app bash
 symfony composer req orm symfony/apache-pack
 symfony composer req &lt;span class="nt"&gt;--dev&lt;/span&gt; symfony/maker-bundle symfony/profiler-pack
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To connect the application to the database, set the &lt;code&gt;DATABASE_URL&lt;/code&gt; to point to the &lt;code&gt;db&lt;/code&gt; service in the &lt;code&gt;.env&lt;/code&gt; file.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;DATABASE_URL="mysql://app_development:password@db:3306/app_db?serverVersion=8.0.32&amp;amp;charset=utf8mb4"&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Filr57kgc65ysi9s33jhm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Filr57kgc65ysi9s33jhm.png" alt="Image description" width="800" height="212"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;At this time, you have a complete Symfony web application with core packages and bundles to start building.&lt;/p&gt;

&lt;p&gt;The complete source code is found here: &lt;a href="https://github.com/gmurambadoro/symfony-lamp-stack-with-docker"&gt;https://github.com/gmurambadoro/symfony-lamp-stack-with-docker&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>symfony</category>
      <category>docker</category>
      <category>webdev</category>
    </item>
    <item>
      <title>8 Months into Linux ..Mint</title>
      <dc:creator>Gavin Murambadoro</dc:creator>
      <pubDate>Wed, 11 Dec 2019 03:41:40 +0000</pubDate>
      <link>https://forem.com/gmurambadoro/8-months-into-linux-mint-2cjl</link>
      <guid>https://forem.com/gmurambadoro/8-months-into-linux-mint-2cjl</guid>
      <description>&lt;p&gt;This month marks roughly about eight months since I started using Linux (more precisely Linux Mint (LM)) and I have decided to share my experiences thus far.&lt;/p&gt;

&lt;p&gt;I wrote about &lt;a href="https://dev.to/gmurambadoro/my-journey-from-windows-to-linux-mint-2o2p"&gt;My Journey from Windows to Linux ..Mint&lt;/a&gt; in this post detailing what really drove me to this operating system.&lt;/p&gt;

&lt;p&gt;Linux Mint as one of the many Linux distros out there has fit comfortably in my day-to-day workflow as a software developer. Below I list some of the cool things I have found Linux Mint to be simplifying my life.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Non-intrusive System Update Notification  - a small icon on the panel is the only notification you see when Linux Mint is due for an update. You can choose to ignore the notification if you want to continue with your work and be productive.&lt;/li&gt;
&lt;li&gt;Transparent System Update Process - with Linux Mint, software updates are categorized into categories e.g. Security, software... and for each update a detailed changelog is available. This means you know what each update does beforehand and you can choose to ignore the update if you so wish. I like this feature a lot.&lt;/li&gt;
&lt;li&gt;Optimized Packages for Software Installation and Updates - whenever you install or update software in LM the updates are packaged in highly compressed files. This means that you not only safe on data costs but the update process becomes faster and much more efficient. I remember this one time when I had to install Microsoft Office and the download itself was +4.5GB in size.&lt;/li&gt;
&lt;li&gt;Rich App Ecosystem / Repository - with the Software Manager you can find all the apps you need in one place which I find really convenient. LM also supports Flatpak, Snap Store and other popular software centres as well. There are tonnes of great open source software available like LibreOffice, Okular PDF, VLC etc which compete with the proprietary versions of Office, Adobe, Windows Media Players that a lot of people are accustomed to. For a developer like myself, I find that my tools of the trade like PHPStorm, MySQL Workbench, VirtualBox and the like are natively supported which is a great plus for me.&lt;/li&gt;
&lt;li&gt;Low Memory Footprint - I found that for the same decent set of hardware resources LM out-performs Windows 10 by miles. Boot up times are much faster and operating system memory usage is much lower as compared to Windows 10. This means that the OS allows me to be productive without getting into my way.&lt;/li&gt;
&lt;li&gt;Out-of-the-Box Printer Support for most printers - LM comes by default with support for most printers meaning you don't have to spend time finding drivers for a new printer you want to use.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;There are loads more great features I enjoy about LM but these are the top ones I could think of at the moment.&lt;/p&gt;

&lt;p&gt;Even though I have mostly enjoyed using LM so far, I have encountered a few challenges that I will list below:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Sometimes my Cinnamon crashes and will need to be restarted. There is a dedicated "Restart Cinnamon" button available which means the developers are aware of this issue occurring from time to time :)&lt;/li&gt;
&lt;li&gt;Sometimes you will need to hit the console in order to fix something or carry out a certain task. If you are not coming from a development background this can be a challenge. However, the more you work with the console the more you realize how powerful it is.&lt;/li&gt;
&lt;li&gt;When starting out initially especially after coming from Windows you will realize that you will need to re-install the OS every now and then (at least that was true for me) after making some breaking changes. I think this is blamed more on teething issues rather than the OS itself.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Despite these issues LM is indeed a joy to work with. However, I don't want to waste any more of your time but if you are a Windows user I suggest you give LM (or any other Linux distro) a try and I promise you won't regret it.&lt;/p&gt;

&lt;p&gt;Cheers and Linux ..Mint FTW.&lt;/p&gt;

</description>
      <category>linux</category>
      <category>beginners</category>
    </item>
    <item>
      <title>My Journey from Windows to Linux ..Mint</title>
      <dc:creator>Gavin Murambadoro</dc:creator>
      <pubDate>Fri, 18 Oct 2019 15:16:53 +0000</pubDate>
      <link>https://forem.com/gmurambadoro/my-journey-from-windows-to-linux-mint-2o2p</link>
      <guid>https://forem.com/gmurambadoro/my-journey-from-windows-to-linux-mint-2o2p</guid>
      <description>&lt;p&gt;Hi everyone and thanks for being an awesome community. &lt;/p&gt;

&lt;p&gt;This is my first post and I am going to share my journey from using Windows as a primary desktop operating system to using Linux Mint. &lt;/p&gt;

&lt;p&gt;Thanks for reading and I hope you will like it. Here goes...&lt;/p&gt;

&lt;p&gt;My first real encounter with a computer was back in 2003 when I used a Windows XP machine to create an email address for a college project. Unbelievable, right? But hey, back in the day computers were not that personal in the parts of the world I grew up in.&lt;/p&gt;

&lt;p&gt;To cut the long story short, I managed to own a personal computer soon after that which was a Windows XP desktop. I used the computer primarily to complete assignment projects as well as play music and watch movies.&lt;/p&gt;

&lt;p&gt;The way the computer worked fascinated me so much that midway though my college degree I decided to drop out and enrol for a Computer Science degree instead. Crazy right? But I had already set my mind up that software development was a career path I wanted to follow.&lt;/p&gt;

&lt;p&gt;For me the computer was now a tool of the trade and no longer an entertainment gadget. My expectations of the personal computer changed because of this and below were my expectations of what a computer should deliver-:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Easy to use&lt;/li&gt;
&lt;li&gt;Reliable&lt;/li&gt;
&lt;li&gt;Performant&lt;/li&gt;
&lt;li&gt;Secure&lt;/li&gt;
&lt;li&gt;Affordable to buy and maintain.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;My Windows XP machine fulfilled most of these requirements for me most of the time. However, as newer versions of Windows were released these expectations started to become threatened one way or the other.&lt;/p&gt;

&lt;p&gt;With each version of Windows that was released (except maybe for Windows 7) I was left questioning whether my core expectations were still being met. I was also starting to feel less and less in control of my desktop computer, as most of the functionality started to be removed or was moved over to the cloud.&lt;/p&gt;

&lt;p&gt;This got me to start thinking about switching to an alternative desktop operating system that stayed true to "my core values". Unfortunately for me the only alternative desktop I was aware of at that time was Mac. However I could not afford a MacBook and I also felt that it was too complicated to use based on a handful of encounters I had with it.&lt;/p&gt;

&lt;p&gt;After I graduated from college in 2012 I was fortunate enough to find a job as a Junior Software Developer in Johannesburg South Africa.&lt;/p&gt;

&lt;p&gt;This was around the time when Windows 7 was still the dominant operating system for Windows. As a developer we focused a lot on hardware integration and access control software for buildings and residential estates. We used C# as the primary development language and we worked with many low level SDKs to integrate our software with devices like fingerprint scanners and CCTV cameras.&lt;/p&gt;

&lt;p&gt;I really loved what we did and was enthused at how Windows worked at such a lower level.&lt;/p&gt;

&lt;p&gt;As a developer I was also tasked in writing small web-based applications that would support the needs of the company. For example I built an incidence report web-application that allowed clients to log faults remotely and be able to track the status of the query and communicate with technicians online.&lt;/p&gt;

&lt;p&gt;This experience exposed me to open source technologies like Linux and PHP. I didn't know that one could be able to do cool stuff outside of Windows and closed source.&lt;/p&gt;

&lt;p&gt;As time went on I started to focus more and more on web development and that's when tools like cygwin and xampp for Windows became more and more important. These allowed me to work on Windows as if I was on a Linux server. Pretty cool hey? I agree...&lt;/p&gt;

&lt;p&gt;All this time I was using Windows 7 even though Windows 8 was now the official operating system for Microsoft. However, like most people I refused to use Windows 8 and tightly clung to Windows 7 as if my life depended on it.&lt;/p&gt;

&lt;p&gt;Seeing that Windows 7 was a failure, Microsoft developed Windows 10 in an attempt to fix the issues that were raised in the Windows 8 release. For example the "Start" button was brought back and Metro UI concept was eased up a bit. But still Windows 10 looked like Windows 8 in a way and many users like me held on to their versions of Windows 7 which we "trusted".&lt;/p&gt;

&lt;p&gt;Then Microsoft decided to "entice" users to upgrade to Windows for free because they were going to discontinue support for Windows 7. There was no choice left for me other that to upgrade.&lt;/p&gt;

&lt;p&gt;I remember having to spend something like 3-6 hours upgrading my PC to Windows 10 over the internet connection I had (this was not a fast connection at all). I think the ISO file itself was at least 4GB in size.&lt;/p&gt;

&lt;p&gt;Even though Windows 10 looked "modern" on the UI front, it was a resource hog. Almost every now and then there seemed to be an update that needed to be made to the operating system and this maintenance routine started to get into my way. Applications used to hang every now and then and I had to spend money to buy extra memory. Even then the performance boost wasn't that much.&lt;/p&gt;

&lt;p&gt;A PC for me is a tool I use to accomplish a task, the more I use this tool the more I could get things done. Windows was literally preventing me from getting things done.&lt;/p&gt;

&lt;p&gt;My critical software like cygwin or xampp/wampp would often stop working after some major security updates. Sigh...&lt;/p&gt;

&lt;p&gt;This is a period I started to see that more and more developers online were not using Windows anymore but were on MacBooks or Linux machines. I decided to give Linux a try (like I said before I cannot afford a MacBook) and I started to spend more time researching about Linux as a desktop operating system and how it could fit into my work space.&lt;/p&gt;

&lt;p&gt;And boy was I completely overwhelmed! After learning that Linux was the third most used desktop operating system, I soon found out that there were actually many versions of Linux to choose from - called distributions. It's not one operating system like Windows or Mac.  There is Ubuntu, Manjaro, Linux Mint, Gentoo, Zorin. You name it, they have it...&lt;/p&gt;

&lt;p&gt;My first problem with this choice was that I could not make up my mind on which "version" to use. I found myself distro-hopping between versions every other day. &lt;/p&gt;

&lt;p&gt;I first tried out all the flavours of Ubuntu but they always felt a bit off for me. Then I tried out Linux Mint which at first felt more natural for me. However the "green" theme of Linux Mint made it difficult for me to want to adopt it - I din't like green. I continued distro-hopping on a few more distros like Manjaro and Pop!_OS but still I always felt as if I was missing something and kept coming back to Windows.&lt;/p&gt;

&lt;p&gt;However, I remember one day I was in the support department when my colleague asked how I felt about Linux considering I had told him before that I was checking out Linux to see if it was for me.&lt;/p&gt;

&lt;p&gt;That was an opportunity to let it all out and told him of all the frustrations I had had with it thus far. How it was "different" and "how it was complicated to find the proper distro". Not to mention the file permissions thing... I could go on and on.&lt;/p&gt;

&lt;p&gt;Then he said, "Gavin. Stop for a second and I will help you out." He was indeed my guardian angel. &lt;/p&gt;

&lt;p&gt;He showed me all the cool stuff that Linux could do and also showed me how fundamentally different it was to Windows.&lt;/p&gt;

&lt;p&gt;He showed me the limitations of Linux in the app space in terms of the fact that mainstream applications like Adobe, Outlook and Word were not available. But he also showed me the alternative software I could use.&lt;/p&gt;

&lt;p&gt;Every day he would check up on me to see how I was doing and tried to assist me in any way that he could.&lt;/p&gt;

&lt;p&gt;After about a month or two I became more comfortable with Linux and eventually settled for Linux Mint (Cinnamon Edition) - I even like the "green" theme of Mint nowadays :)&lt;/p&gt;

&lt;p&gt;I can say now I have been using Linux Mint as my primary desktop operating for my work computer and both of my home computers.&lt;/p&gt;

&lt;p&gt;Only my home laptop has a dual boot with Windows 10 because I still have some .NET projects I maintain and are developed in C#. Plus my wife still loves Excel and Word and I cannot convince her to convert. At least not yet.&lt;/p&gt;

&lt;p&gt;Before I finish off I'd like to say that I am proud of the decision I have made to switch to Linux from Windows.&lt;/p&gt;

&lt;p&gt;I think with Linux as my desktop I have managed to regain the 4 qualities I expected from a desktop operating system i.e. ease of use, reliability, performance and security.&lt;/p&gt;

&lt;p&gt;I would also like to thank the community for also helping out and assisting noobs like me to get on board such an awesome operating system.&lt;/p&gt;

&lt;p&gt;Thanks for reading. Linux FTW.&lt;/p&gt;

&lt;p&gt;Cheers to more posts.&lt;/p&gt;

</description>
      <category>linux</category>
      <category>cinnamon</category>
      <category>beginners</category>
    </item>
  </channel>
</rss>
