Windows Linux subsystem setup.
sudo apt-get install mariadb-server
sudo service mysql start
sudo mysql_secure_installation
sudo apt install phpmyadmin
sudo cp /etc/phpmyadmin/apache.conf /etc/apache2/conf-enabled/phpmyadmin.conf
sudo service apache2 restart
Add mysql user for phpmyadmin
sudo mysql -u root -p
CREATE USER 'sql'@'localhost' IDENTIFIED BY '';
GRANT ALL PRIVILEGES ON * . * TO 'sql'@'localhost';
FLUSH PRIVILEGES;Allow empty passwords for PhpMyAdmin
sudo nano /etc/phpmyadmin/config.inc.php
Uncomment this line: $cfg['Servers'][$i]['AllowNoPassword'] = TRUE;
ssh-keygen -t rsa -b 4096 -C "your_email@example.com"
eval $(ssh-agent -s)
ssh-add ~/.ssh/id_rsa
Output ssh key for github: cat ~/.ssh/id_rsa.pub
Follow introductions from https://getcomposer.org/download/
mv composer.phar /usr/local/bin/composer
sudo apt-get install php7.2-intl
Create a new apache vhost
sudo nano /etc/apache2/sites-available/myapp.test.conf
Vhost config (Optimzed for symlinked Symfony 3.4/Contao 4.4 project folder):
<VirtualHost *:80>
ServerName myapp.test
ServerAdmin webmaster@localhost
DocumentRoot /var/www/myapp/web
<Directory /var/www/myapp/web>
AllowOverride All
Order Allow,Deny
Allow from All
</Directory>
<Directory /var/www>
Options FollowSymlinks
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
Activate page and restart apache:
sudo a2ensite myapp.test
sudo service apache2 restart
Edit as Admin: c:\windows\system32\drivers\etc
Add:
127.0.0.1 myapp.test
/etc/wsl.conf
[automount]
enabled=true
options=metadata,uid=1000,gid=1000,umask=022