[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"$f89iTpv8kwxdFKfzGFTiNgczeSV2jyfeA1FMLpG2nzXc":3},{"id":4,"title":5,"teaser":6,"body":7,"slug":8,"date":9,"coverImage":10,"tags":15},"d3615723-6ca1-4372-888f-ea0727cdf696","Setting up WSL on Windows 11 for Drupal 11 development","","\u003Cp>Coming from an Ubuntu Linux background, I’m all about that streamlined development environment, but let's be real - sometimes you need to game, listen to music, and hop on a few meetings without juggling multiple devices. Enter the gaming PC: a powerhouse that lets me keep work and play separate. But don’t worry, Linux still has a seat at the table.\u003C\u002Fp>\u003Cp>When I switched to Windows 11, I wanted to keep my Linux efficiency while also diving into the sweet world of gaming. WSL (Windows Subsystem for Linux) was the perfect bridge between these two worlds, letting me enjoy my Linux workflows without giving up the joys of PC gaming.\u003C\u002Fp>\u003Cp>WSL allows me to run a full Ubuntu environment right inside Windows. This means I can use all the tools I loved on Linux, minus the mess of WAMP or XAMPP - those dinosaurs should be extinct by now. With WSL, I can run my entire Drupal stack natively, with Linux commands and scripts, just like the good old days on Ubuntu. No need to deal with the ghosts of local development past!\u003C\u002Fp>\u003Cp>To make life even smoother, I set up a shortcut to launch WSL without needing admin rights:\u003C\u002Fp>\u003Col>\u003Cli>\u003Cstrong>Create the shortcut:\u003C\u002Fstrong>\u003Cul>\u003Cli>Right-click on the desktop, select \u003Cstrong>New &gt; Shortcut\u003C\u002Fstrong>.\u003C\u002Fli>\u003Cli>Set the location to \u003Ccode>C:\\Windows\\System32\\wsl.exe\u003C\u002Fcode>.\u003C\u002Fli>\u003Cli>Name the shortcut (something cool like \"WSL Terminal\") and click \u003Cstrong>Finish\u003C\u002Fstrong>.\u003C\u002Fli>\u003C\u002Ful>\u003C\u002Fli>\u003Cli>\u003Cstrong>Assign a keyboard shortcut:\u003C\u002Fstrong>\u003Cul>\u003Cli>Right-click the shortcut, go to \u003Cstrong>Properties\u003C\u002Fstrong>.\u003C\u002Fli>\u003Cli>In the \u003Cstrong>Shortcut\u003C\u002Fstrong> tab, click the \u003Cstrong>Shortcut key\u003C\u002Fstrong> field and press \u003Ccode>Ctrl + Alt + T\u003C\u002Fcode>.\u003C\u002Fli>\u003Cli>Click \u003Cstrong>Apply\u003C\u002Fstrong>, then \u003Cstrong>OK\u003C\u002Fstrong>.\u003C\u002Fli>\u003C\u002Ful>\u003C\u002Fli>\u003C\u002Fol>\u003Cp>Now, with a quick keyboard shortcut, I can dive straight into my WSL environment, keeping development fast and efficient. It’s like having the best of both worlds: the power and familiarity of Linux for development and the gaming prowess of Windows 11 for, well, everything else.\u003C\u002Fp>\u003Cp>No more fighting with WAMP or XAMPP—just a clean, effective, and powerful way to develop Drupal locally.\u003C\u002Fp>\u003Cp>&nbsp;\u003C\u002Fp>\u003Cimg src=\"\u002Fsites\u002Fdefault\u002Ffiles\u002Finline-images\u002F55%2BHilarious-developer-memes-that-will-leave-you-in-splits-49.jpg\" data-entity-uuid=\"6752a843-c09d-4fe3-9c42-f8d5ea7efa58\" data-entity-type=\"file\" width=\"504\" height=\"475\" class=\"align-center\" loading=\"lazy\">\u003Cp>\u003Cbr>\u003Cstrong>Quick Start: Setting Up Ubuntu on WSL for Drupal Development\u003C\u002Fstrong>\u003C\u002Fp>\u003Ch2>Quick Start: Setting Up Drupal with DDEV on WSL\u003C\u002Fh2>\u003Cp>Say goodbye to those clunky local setups - here’s how to set up your Drupal development environment using DDEV on Ubuntu within WSL. It’s the modern way to do things, leaving WAMP, XAMPP, and their outdated friends in the dust.\u003C\u002Fp>\u003Col>\u003Cli>\u003Cp>\u003Cstrong>Install WSL and Ubuntu 22.04 LTS:\u003C\u002Fstrong>\u003C\u002Fp>\u003Cul>\u003Cli>Open PowerShell as admin and run:\u003C\u002Fli>\u003C\u002Ful>\u003Cpre>\u003Ccode class=\"language-plaintext\">wsl --install\u003C\u002Fcode>\u003C\u002Fpre>\u003Cul>\u003Cli>This installs WSL along with the default Ubuntu distribution. If you want the latest Ubuntu 22.04 LTS, just ensure it’s updated after installation. Restart your machine if prompted.\u003C\u002Fli>\u003C\u002Ful>\u003C\u002Fli>\u003Cli>\u003Cp>\u003Cstrong>Set up Docker and DDEV:\u003C\u002Fstrong>\u003C\u002Fp>\u003Cul>\u003Cli>Launch Ubuntu from the Start menu or by typing \u003Ccode>wsl\u003C\u002Fcode> in your terminal.\u003C\u002Fli>\u003Cli>Install Docker by following the official \u003Ca href=\"https:\u002F\u002Fdocs.docker.com\u002Fengine\u002Finstall\u002Fubuntu\u002F\">Docker on Ubuntu guide\u003C\u002Fa>. Make sure Docker is up and running within WSL.\u003C\u002Fli>\u003Cli>Install DDEV using the official script:\u003C\u002Fli>\u003C\u002Ful>\u003Cpre>\u003Ccode class=\"language-plaintext\">sudo apt-get install -y bash-completion apt-transport-https ca-certificates software-properties-common\ncurl -L https:\u002F\u002Fraw.githubusercontent.com\u002Fdrud\u002Fddev\u002Fmaster\u002Fscripts\u002Finstall_ddev.sh | bash\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fli>\u003Cli>\u003Cp>\u003Cstrong>Create your Drupal project:\u003C\u002Fstrong>\u003C\u002Fp>\u003Cul>\u003Cli>Navigate to your project directory:\u003C\u002Fli>\u003C\u002Ful>\u003Cpre>\u003Ccode class=\"language-plaintext\">cd ~\u002Fprojects\u003C\u002Fcode>\u003C\u002Fpre>\u003Cul>\u003Cli>Set up a new Drupal project using DDEV:\u003C\u002Fli>\u003C\u002Ful>\u003Cpre>\u003Ccode class=\"language-plaintext\">ddev config --project-type=drupal9 --docroot=web --create-docroot\nddev start\u003C\u002Fcode>\u003C\u002Fpre>\u003Cul>\u003Cli>Install Drupal using Drush:\u003C\u002Fli>\u003C\u002Ful>\u003Cpre>\u003Ccode class=\"language-plaintext\">ddev drush site:install\u003C\u002Fcode>\u003C\u002Fpre>\u003C\u002Fli>\u003Cli>\u003Cstrong>Access your Drupal site:\u003C\u002Fstrong>\u003Cul>\u003Cli>Once DDEV has started your project, access your Drupal site by navigating to \u003Ccode>https:\u002F\u002F&lt;projectname&gt;.ddev.site\u003C\u002Fcode> in your web browser.\u003C\u002Fli>\u003C\u002Ful>\u003C\u002Fli>\u003Cli>\u003Cstrong>Forget the clunky old stacks:\u003C\u002Fstrong>\u003Cul>\u003Cli>With DDEV on WSL, you’re running a modern, containerized development environment that’s fast, flexible, and easy to manage. No more fighting with outdated local setups!\u003C\u002Fli>\u003C\u002Ful>\u003C\u002Fli>\u003C\u002Fol>\u003Cp>Now you're ready to develop Drupal like a pro, using the best tools for the job. DDEV and WSL together offer a powerful, efficient setup that leaves those old local development methods in the dust. Happy gaming and coding!\u003C\u002Fp>","setting-wsl-windows-11-drupal-11-development","2024-08-17T14:58:37+00:00",{"id":11,"url":12,"alt":5,"width":13,"height":14},"93ded84f-d007-4b14-b035-baf96cc5c1b5","\u002Fsites\u002Fdefault\u002Ffiles\u002F2024-08\u002Fa41e13e7e9666015753f1183cad17410.jpg",736,299,[]]