Skip to content

Instantly share code, notes, and snippets.

@jmolivas
Last active July 4, 2017 17:56
Show Gist options
  • Save jmolivas/028f44d3a505892d65dbde25ccccb4af to your computer and use it in GitHub Desktop.
Save jmolivas/028f44d3a505892d65dbde25ccccb4af to your computer and use it in GitHub Desktop.
Download Drupal 8 + DrupalConsole using DrupalComposer

Install Composer
https://getcomposer.org/download/

Install DrupalConsole launcher tool

curl https://drupalconsole.com/installer -L -o drupal.phar
mv drupal.phar /usr/local/bin/drupal
chmod +x /usr/local/bin/drupal

Download Drupal + DrupalConsole

composer create-project \
drupal-composer/drupal-project:8.x-dev \
drupal8.dev \
--prefer-dist \
--no-progress \
--no-interaction

Change to new created directory

cd drupal8.dev/

Verify DrupalConsole downloaded versions

composer show | grep drupal/console

Verify DrupalCore downloaded version

composer show | grep drupal/core

Copy configuration files (make sure you answer yes to first question)

drupal init

Install Drupal (enter your DB credentials)

drupal site:install

Show available commands

drupal list

Test some commands

drupal generate:module
drupal generate:controller

drupal router:debug
drupal plugin:debug
drupal container:debug
@rpsu
Copy link

rpsu commented Oct 7, 2016

I assume these are for OSX?
One addition to have would be a test to see that composer actually does work (mine did not, as I did not have it yet installed globally). Might want to add a link to getcomposer.org -site (to the correct documentation page)

@jmolivas
Copy link
Author

jmolivas commented Oct 7, 2016

@rpsu link to Install Composer https://getcomposer.org/download/ added

@rpsu
Copy link

rpsu commented Oct 11, 2016

Thanks - other than that this is neat and simple set of instructions to get the D8 site up.
What I also did is this to get in running locally:
cd web; php -S localhost:8081
just to keep thing simple and have no hassle with (other) webservers like nginx or apache

@jmolivas
Copy link
Author

jmolivas commented Nov 4, 2016

@rpsu you can run the php built-in server executing the DrupalConsole server command as drupal server or you can also pass arguments like drupal server 127.0.0.1:8080

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment