Find a file
2020-02-17 12:44:49 +00:00
assets/web Move and link web assets 2020-02-17 12:26:51 +00:00
docs Add README 2019-12-08 22:01:14 +00:00
.gitignore Remove and ignore composer.lock 2020-02-17 12:44:49 +00:00
.php-version Set the PHP version to 7.3 2019-12-08 21:47:03 +00:00
composer.json Revert "Add examples module" 2020-02-17 12:43:44 +00:00
docker-compose.yaml Add MySQL service with Docker 2019-12-08 21:46:25 +00:00
php.ini Set timezone to Europe/London 2019-12-08 21:47:03 +00:00
README.md Add usage instructions 2020-02-17 12:29:00 +00:00

Testing the Symfony Local Server with Drupal

An example of running Drupal 8.8 on Symfonys local web server.

A screenshot of Drupal's status page showing Symfony Local Server

Usage

  1. Install the Symfony CLI from https://symfony.com/download.
  2. Clone this repository
    git clone https://github.com/opdavies/symfony-server-drupal-test.git
    
    cd symfony-server-drupal-test
    
  3. Run composer install to download all of the projects dependencies (Drupal core, Examples module etc).
  4. Run docker-compose up -d to start the Docker container for MySQL. (You can run docker-compose ps afterwards to confirm that its running).
  5. Run symfony server:start to start the web server.
  6. Use Drush to install Drupal, prefixed by symfony php to allow access to the environment variables needed in settings.php:
    cd web
    
    symfony php ../vendor/bin/drush site:install --no-interaction
    
  7. Go to http://127.0.0.1:8000 to view the site.
  8. To run tests, PHPUnit also needs to be prefixed with symfony php:
    cd web
    
    symfony php ../vendor/bin/phpunit -c core core/modules/action
    
  9. Run symfony server:stop to stop the web server.