diff --git a/.gitignore b/.gitignore index e5218568eb..f7742d102b 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ /patches /vendor /bin +Makefile.local diff --git a/Makefile b/Makefile new file mode 100644 index 0000000000..12d3c49e8d --- /dev/null +++ b/Makefile @@ -0,0 +1,95 @@ +#!/usr/bin/make -f + +APP_ROOT=$(CURDIR)/app +PHP=$(which php) +PHPCS_EXTENSIONS=php,module,inc,install,test,profile,theme +PHPCS_IGNORE=*.md,*.css,*.txt +PHPCS_COMMON_OPTIONS=--standard=vendor/drupal/coder/coder_sniffer/Drupal/ruleset.xml --extensions=$(PHPCS_EXTENSIONS) --ignore=$(PHPCS_IGNORE) +BUILD_LOGS_DIR=$(CURDIR)/build/logs +ARCH=$(shell uname -m) +APP_URL=http://127.0.0.1 +BROWSERTEST_OUTPUT_DIRECTORY=$(APP_ROOT)/sites/default/files +PHANTOMJS_DIR=$(HOME)/.phantomjs +PHANTOMJS_BIN=$(HOME)/.phantomjs/phantomjs-2.1.1-linux-$(ARCH)/bin/phantomjs +DRUSH=$(CURDIR)/bin/drush +DC=$(CURDIR)/bin/drupal +SITE_NAME=Drupal8 +EMAIL=admin@127.0.0.1 +USERNAME=admin +PASSWORD=password +PROFILE=standard +MODULES_ENABLE=0 +MYSQL_HOST=127.0.0.1 +MYSQL_PORT=3306 +MYSQL_DATABASE=local +MYSQL_USER=drupal +MYSQL_PASS=drupal +MYSQL_QUERY_STRING=mysql://$(MYSQL_USER):$(MYSQL_PASS)@$(MYSQL_HOST)/$(MYSQL_DATABASE) +list: + @$(MAKE) -pRrq -f $(lastword $(MAKEFILE_LIST)) : 2>/dev/null | awk -v RS= -F: '/^# File/,/^# Finished Make data base/ {if ($$1 !~ "^[#.]") {print $$1n}}' | sort | egrep -v -e '^[^[:alnum:]]' -e '^$@$$' + +prepare: + composer install --prefer-dist + +install: + $(DRUSH) -r $(APP_ROOT) site-install $(PROFILE) -y --db-url=$(MYSQL_QUERY_STRING) --sites-subdir="default" --account-mail=$(EMAIL) --account-name=$(USERNAME) --account-pass=$(PASSWORD) --site-name=$(SITE_NAME) install_configure_form.site_default_country=AU install_configure_form.date_default_timezone=Australia/Sydney + +re-install: db-drop clean-up copy-files install simple-enable login + +clean-up: + rm -fR $(APP_ROOT)/sites/default/files/* + +copy-files: + cp $(APP_ROOT)/sites/default/default.settings.php $(APP_ROOT)/sites/default/settings.php + chmod 777 $(APP_ROOT)/sites/default/settings.php + cp $(APP_ROOT)/sites/default/default.services.yml $(APP_ROOT)/sites/default/services.yml + chmod 777 $(APP_ROOT)/sites/default/services.yml + +db-drop: + $(DRUSH) -r $(APP_ROOT) sql-drop -y + +simple-enable: + $(DRUSH) -r $(APP_ROOT) en simpletest --uri=$(APP_URL) -y + +simple-test: + @while [ -z "$$CLASS" ]; do \ + read -r -p "Class name: " CLASS; \ + done ; \ + $(PHP) $(APP_ROOT)/core/scripts/run-tests.sh --php $(PHP) --concurrency 12 --url $(APP_URL) --verbose --color --class '$$CLASS' + +test: + $(APP_ROOT)/vendor/bin/phpunit -d -v -c $(APP_ROOT)/core/phpunit.xml.dist;cat $(APP_ROOT)/test-output.html;echo "" > $(APP_ROOT)/test-output.html + +test-filter: + @while [ -z "$$GROUP" ]; do \ + read -r -p "Filter group: " GROUP; \ + done ; \ + $(APP_ROOT)/vendor/bin/phpunit -c $(APP_ROOT)/core/phpunit.xml --filter=$$GROUP;cat $(APP_ROOT)/test-output.html;echo "" > $(APP_ROOT)/test-output.html + +phantomjs: phantomjs-stop phantom-init + ${PHANTOMJS_BIN} --ssl-protocol=any --ignore-ssl-errors=true $(APP_ROOT)/vendor/jcalderonzumba/gastonjs/src/Client/main.js 8510 1024 768 2>&1 >> /dev/null & + ps axo pid,command | grep phantomjs | grep -v grep | grep -v make + +phantom-init: + if [ ! -d ${PHANTOMJS_DIR} ]; then mkdir -p ${PHANTOMJS_DIR}; wget --no-check-certificate https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-2.1.1-linux-$(ARCH).tar.bz2 -O ${PHANTOMJS_DIR}/phantomjs-2.1.1-linux-x86_64.tar.bz2; tar -xvf ${PHANTOMJS_DIR}/phantomjs-2.1.1-linux-x86_64.tar.bz2 -C ${PHANTOMJS_DIR}; else echo "PhantomJS already exists"; fi + +phantomjs-stop: + ps axo pid,command | grep phantomjs | grep -v grep | grep -v make | awk '{print $$1}' | xargs -I {} kill {} + ps axo pid,command | grep php | grep -v grep | grep -v phpstorm | grep -v make | awk '{print $$1}' | xargs -I {} kill {} + +login: + $(DRUSH) -r $(APP_ROOT) uli --uri=$(APP_URL) + +phpcbf: + @while [ -z "$$FOLDER" ]; do \ + read -r -p "Folder path: " FOLDER; \ + done ; \ + $(CURDIR)/bin/phpcbf --report=full $(PHPCS_COMMON_OPTIONS) $$FOLDER + +phpcs: + @while [ -z "$$FOLDER" ]; do \ + read -r -p "Folder path: " FOLDER; \ + done ; \ + $(CURDIR)/bin/phpcs --report=full $(PHPCS_COMMON_OPTIONS) $$FOLDER + +-include Makefile.local diff --git a/Vagrantfile b/Vagrantfile deleted file mode 100644 index 31b71ff171..0000000000 --- a/Vagrantfile +++ /dev/null @@ -1,14 +0,0 @@ -Vagrant.configure("2") do |config| - config.vm.define 'lamp', primary: true do |lamp| - lamp.vm.box = 'pnx/lamp' - lamp.vm.hostname = 'd8.dev' - - # This script is a last chance for Developers to add more - # configuration to the Vagrant host. - # - # Examples: - # * Create files directories - # * Setup additional databases - # lamp.vm.provision :shell, path: "provision.sh" - end -end diff --git a/build.xml b/build.xml deleted file mode 100644 index 3ffa641235..0000000000 --- a/build.xml +++ /dev/null @@ -1,188 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/composer.json b/composer.json index b99fee9e3f..50aa4f0ca5 100644 --- a/composer.json +++ b/composer.json @@ -2,16 +2,11 @@ "name": "nickschuch/vd8", "description": "Vagrant for Drupal 8", "require": { - "drush/drush": "~8.1", - "phing/phing": "~2.12", - "drupal/coder": "~8.2" + "drush/drush": "^9.5" }, "minimum-stability": "dev", "prefer-stable": true, "config": { "bin-dir": "bin/" - }, - "installer-paths": { - "vendor/drupal/{$name}": ["drupal/coder"] } } diff --git a/composer.lock b/composer.lock deleted file mode 100644 index 9fdedaafff..0000000000 --- a/composer.lock +++ /dev/null @@ -1,1324 +0,0 @@ -{ - "_readme": [ - "This file locks the dependencies of your project to a known state", - "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", - "This file is @generated automatically" - ], - "content-hash": "71c3fd79deb4c0e54c8d978b1b5cb207", - "packages": [ - { - "name": "consolidation/annotated-command", - "version": "2.4.8", - "source": { - "type": "git", - "url": "https://github.com/consolidation/annotated-command.git", - "reference": "6672ea38212f8bffb71fec7eadc8b3372154b17e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/consolidation/annotated-command/zipball/6672ea38212f8bffb71fec7eadc8b3372154b17e", - "reference": "6672ea38212f8bffb71fec7eadc8b3372154b17e", - "shasum": "" - }, - "require": { - "consolidation/output-formatters": "^3.1.5", - "php": ">=5.4.0", - "phpdocumentor/reflection-docblock": "^2.0|^3.0.2", - "psr/log": "^1", - "symfony/console": "^2.8|~3", - "symfony/event-dispatcher": "^2.5|^3", - "symfony/finder": "^2.5|^3" - }, - "require-dev": { - "phpunit/phpunit": "^4.8", - "satooshi/php-coveralls": "^1.0", - "squizlabs/php_codesniffer": "^2.7" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.x-dev" - } - }, - "autoload": { - "psr-4": { - "Consolidation\\AnnotatedCommand\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Greg Anderson", - "email": "greg.1.anderson@greenknowe.org" - } - ], - "description": "Initialize Symfony Console commands from annotated command class methods.", - "time": "2017-04-03T22:37:00+00:00" - }, - { - "name": "consolidation/output-formatters", - "version": "3.1.8", - "source": { - "type": "git", - "url": "https://github.com/consolidation/output-formatters.git", - "reference": "0b50ba1134d581fd55376f3e21508dab009ced47" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/consolidation/output-formatters/zipball/0b50ba1134d581fd55376f3e21508dab009ced47", - "reference": "0b50ba1134d581fd55376f3e21508dab009ced47", - "shasum": "" - }, - "require": { - "php": ">=5.4.0", - "symfony/console": "^2.8|~3", - "symfony/finder": "~2.5|~3.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.8", - "satooshi/php-coveralls": "^1.0", - "squizlabs/php_codesniffer": "^2.7", - "victorjonsson/markdowndocs": "^1.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.x-dev" - } - }, - "autoload": { - "psr-4": { - "Consolidation\\OutputFormatters\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Greg Anderson", - "email": "greg.1.anderson@greenknowe.org" - } - ], - "description": "Format text by applying transformations provided by plug-in formatters.", - "time": "2017-03-01T20:54:45+00:00" - }, - { - "name": "dnoegel/php-xdg-base-dir", - "version": "0.1", - "source": { - "type": "git", - "url": "https://github.com/dnoegel/php-xdg-base-dir.git", - "reference": "265b8593498b997dc2d31e75b89f053b5cc9621a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/dnoegel/php-xdg-base-dir/zipball/265b8593498b997dc2d31e75b89f053b5cc9621a", - "reference": "265b8593498b997dc2d31e75b89f053b5cc9621a", - "shasum": "" - }, - "require": { - "php": ">=5.3.2" - }, - "require-dev": { - "phpunit/phpunit": "@stable" - }, - "type": "project", - "autoload": { - "psr-4": { - "XdgBaseDir\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "implementation of xdg base directory specification for php", - "time": "2014-10-24T07:27:01+00:00" - }, - { - "name": "drupal/coder", - "version": "8.2.12", - "source": { - "type": "git", - "url": "https://github.com/klausi/coder.git", - "reference": "984c54a7b1e8f27ff1c32348df69712afd86b17f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/klausi/coder/zipball/984c54a7b1e8f27ff1c32348df69712afd86b17f", - "reference": "984c54a7b1e8f27ff1c32348df69712afd86b17f", - "shasum": "" - }, - "require": { - "ext-mbstring": "*", - "php": ">=5.4.0", - "squizlabs/php_codesniffer": ">=2.8.1 <3.0", - "symfony/yaml": ">=2.0.0" - }, - "require-dev": { - "phpunit/phpunit": ">=3.7 <6" - }, - "type": "phpcodesniffer-standard", - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0+" - ], - "description": "Coder is a library to review Drupal code.", - "homepage": "https://www.drupal.org/project/coder", - "keywords": [ - "code review", - "phpcs", - "standards" - ], - "time": "2017-03-18T10:28:49+00:00" - }, - { - "name": "drush/drush", - "version": "8.1.11", - "source": { - "type": "git", - "url": "https://github.com/drush-ops/drush.git", - "reference": "8e7c3308dee06083b6bd065e24e009a34fb71d2a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/drush-ops/drush/zipball/8e7c3308dee06083b6bd065e24e009a34fb71d2a", - "reference": "8e7c3308dee06083b6bd065e24e009a34fb71d2a", - "shasum": "" - }, - "require": { - "consolidation/annotated-command": "~2", - "consolidation/output-formatters": "~3", - "pear/console_table": "~1.3.0", - "php": ">=5.4.5", - "phpdocumentor/reflection-docblock": "^2.0", - "psr/log": "~1.0", - "psy/psysh": "~0.6", - "symfony/console": "~2.7", - "symfony/event-dispatcher": "~2.7", - "symfony/finder": "~2.7", - "symfony/var-dumper": "~2.7", - "symfony/yaml": "~2.3", - "webmozart/path-util": "~2" - }, - "require-dev": { - "phpunit/phpunit": "4.*", - "symfony/process": "2.7.*" - }, - "suggest": { - "drush/config-extra": "Provides configuration workflow commands, such as config-merge.", - "ext-pcntl": "*" - }, - "bin": [ - "drush", - "drush.launcher", - "drush.php", - "drush.complete.sh" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "8.0.x-dev" - } - }, - "autoload": { - "psr-0": { - "Drush": "lib/", - "Consolidation": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "GPL-2.0+" - ], - "authors": [ - { - "name": "Moshe Weitzman", - "email": "weitzman@tejasa.com" - }, - { - "name": "Owen Barton", - "email": "drupal@owenbarton.com" - }, - { - "name": "Mark Sonnabaum", - "email": "marksonnabaum@gmail.com" - }, - { - "name": "Antoine Beaupré", - "email": "anarcat@koumbit.org" - }, - { - "name": "Greg Anderson", - "email": "greg.1.anderson@greenknowe.org" - }, - { - "name": "Jonathan Araña Cruz", - "email": "jonhattan@faita.net" - }, - { - "name": "Jonathan Hedstrom", - "email": "jhedstrom@gmail.com" - }, - { - "name": "Christopher Gervais", - "email": "chris@ergonlogic.com" - }, - { - "name": "Dave Reid", - "email": "dave@davereid.net" - }, - { - "name": "Damian Lee", - "email": "damiankloip@googlemail.com" - } - ], - "description": "Drush is a command line shell and scripting interface for Drupal, a veritable Swiss Army knife designed to make life easier for those of us who spend some of our working hours hacking away at the command prompt.", - "homepage": "http://www.drush.org", - "time": "2017-04-21T21:59:44+00:00" - }, - { - "name": "jakub-onderka/php-console-color", - "version": "0.1", - "source": { - "type": "git", - "url": "https://github.com/JakubOnderka/PHP-Console-Color.git", - "reference": "e0b393dacf7703fc36a4efc3df1435485197e6c1" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/JakubOnderka/PHP-Console-Color/zipball/e0b393dacf7703fc36a4efc3df1435485197e6c1", - "reference": "e0b393dacf7703fc36a4efc3df1435485197e6c1", - "shasum": "" - }, - "require": { - "php": ">=5.3.2" - }, - "require-dev": { - "jakub-onderka/php-code-style": "1.0", - "jakub-onderka/php-parallel-lint": "0.*", - "jakub-onderka/php-var-dump-check": "0.*", - "phpunit/phpunit": "3.7.*", - "squizlabs/php_codesniffer": "1.*" - }, - "type": "library", - "autoload": { - "psr-0": { - "JakubOnderka\\PhpConsoleColor": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-2-Clause" - ], - "authors": [ - { - "name": "Jakub Onderka", - "email": "jakub.onderka@gmail.com", - "homepage": "http://www.acci.cz" - } - ], - "time": "2014-04-08T15:00:19+00:00" - }, - { - "name": "jakub-onderka/php-console-highlighter", - "version": "v0.3.2", - "source": { - "type": "git", - "url": "https://github.com/JakubOnderka/PHP-Console-Highlighter.git", - "reference": "7daa75df45242c8d5b75a22c00a201e7954e4fb5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/JakubOnderka/PHP-Console-Highlighter/zipball/7daa75df45242c8d5b75a22c00a201e7954e4fb5", - "reference": "7daa75df45242c8d5b75a22c00a201e7954e4fb5", - "shasum": "" - }, - "require": { - "jakub-onderka/php-console-color": "~0.1", - "php": ">=5.3.0" - }, - "require-dev": { - "jakub-onderka/php-code-style": "~1.0", - "jakub-onderka/php-parallel-lint": "~0.5", - "jakub-onderka/php-var-dump-check": "~0.1", - "phpunit/phpunit": "~4.0", - "squizlabs/php_codesniffer": "~1.5" - }, - "type": "library", - "autoload": { - "psr-0": { - "JakubOnderka\\PhpConsoleHighlighter": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Jakub Onderka", - "email": "acci@acci.cz", - "homepage": "http://www.acci.cz/" - } - ], - "time": "2015-04-20T18:58:01+00:00" - }, - { - "name": "nikic/php-parser", - "version": "v3.0.5", - "source": { - "type": "git", - "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "2b9e2f71b722f7c53918ab0c25f7646c2013f17d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/2b9e2f71b722f7c53918ab0c25f7646c2013f17d", - "reference": "2b9e2f71b722f7c53918ab0c25f7646c2013f17d", - "shasum": "" - }, - "require": { - "ext-tokenizer": "*", - "php": ">=5.5" - }, - "require-dev": { - "phpunit/phpunit": "~4.0|~5.0" - }, - "bin": [ - "bin/php-parse" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0-dev" - } - }, - "autoload": { - "psr-4": { - "PhpParser\\": "lib/PhpParser" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Nikita Popov" - } - ], - "description": "A PHP parser written in PHP", - "keywords": [ - "parser", - "php" - ], - "time": "2017-03-05T18:23:57+00:00" - }, - { - "name": "pear/console_table", - "version": "v1.3.0", - "source": { - "type": "git", - "url": "https://github.com/pear/Console_Table.git", - "reference": "64100b9ee81852f4fa17823e55d0b385a544f976" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/pear/Console_Table/zipball/64100b9ee81852f4fa17823e55d0b385a544f976", - "reference": "64100b9ee81852f4fa17823e55d0b385a544f976", - "shasum": "" - }, - "require": { - "php": ">=5.2.0" - }, - "suggest": { - "pear/Console_Color2": ">=0.1.2" - }, - "type": "library", - "autoload": { - "classmap": [ - "Table.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-2-Clause" - ], - "authors": [ - { - "name": "Jan Schneider", - "homepage": "http://pear.php.net/user/yunosh" - }, - { - "name": "Tal Peer", - "homepage": "http://pear.php.net/user/tal" - }, - { - "name": "Xavier Noguer", - "homepage": "http://pear.php.net/user/xnoguer" - }, - { - "name": "Richard Heyes", - "homepage": "http://pear.php.net/user/richard" - } - ], - "description": "Library that makes it easy to build console style tables.", - "homepage": "http://pear.php.net/package/Console_Table/", - "keywords": [ - "console" - ], - "time": "2016-01-21T16:14:31+00:00" - }, - { - "name": "phing/phing", - "version": "2.15.2", - "source": { - "type": "git", - "url": "https://github.com/phingofficial/phing.git", - "reference": "0999ab4e94e609dc00998e3d1b88df843054db7c" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phingofficial/phing/zipball/0999ab4e94e609dc00998e3d1b88df843054db7c", - "reference": "0999ab4e94e609dc00998e3d1b88df843054db7c", - "shasum": "" - }, - "require": { - "php": ">=5.2.0" - }, - "require-dev": { - "ext-pdo_sqlite": "*", - "lastcraft/simpletest": "@dev", - "mikey179/vfsstream": "^1.6", - "pdepend/pdepend": "2.x", - "pear/archive_tar": "1.4.x", - "pear/http_request2": "dev-trunk", - "pear/net_growl": "dev-trunk", - "pear/pear-core-minimal": "1.10.1", - "pear/versioncontrol_git": "@dev", - "pear/versioncontrol_svn": "~0.5", - "phpdocumentor/phpdocumentor": "2.x", - "phploc/phploc": "~2.0.6", - "phpmd/phpmd": "~2.2", - "phpunit/phpunit": ">=3.7", - "sebastian/git": "~1.0", - "sebastian/phpcpd": "2.x", - "siad007/versioncontrol_hg": "^1.0", - "squizlabs/php_codesniffer": "~2.2", - "symfony/yaml": "~2.7" - }, - "suggest": { - "pdepend/pdepend": "PHP version of JDepend", - "pear/archive_tar": "Tar file management class", - "pear/versioncontrol_git": "A library that provides OO interface to handle Git repository", - "pear/versioncontrol_svn": "A simple OO-style interface for Subversion, the free/open-source version control system", - "phpdocumentor/phpdocumentor": "Documentation Generator for PHP", - "phploc/phploc": "A tool for quickly measuring the size of a PHP project", - "phpmd/phpmd": "PHP version of PMD tool", - "phpunit/php-code-coverage": "Library that provides collection, processing, and rendering functionality for PHP code coverage information", - "phpunit/phpunit": "The PHP Unit Testing Framework", - "sebastian/phpcpd": "Copy/Paste Detector (CPD) for PHP code", - "siad007/versioncontrol_hg": "A library for interfacing with Mercurial repositories.", - "tedivm/jshrink": "Javascript Minifier built in PHP" - }, - "bin": [ - "bin/phing" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.15.x-dev" - } - }, - "autoload": { - "classmap": [ - "classes/phing/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "include-path": [ - "classes" - ], - "license": [ - "LGPL-3.0" - ], - "authors": [ - { - "name": "Michiel Rook", - "email": "mrook@php.net" - }, - { - "name": "Phing Community", - "homepage": "https://www.phing.info/trac/wiki/Development/Contributors" - } - ], - "description": "PHing Is Not GNU make; it's a PHP project build system or build tool based on Apache Ant.", - "homepage": "https://www.phing.info/", - "keywords": [ - "build", - "phing", - "task", - "tool" - ], - "time": "2016-10-13T09:01:45+00:00" - }, - { - "name": "phpdocumentor/reflection-docblock", - "version": "2.0.4", - "source": { - "type": "git", - "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/d68dbdc53dc358a816f00b300704702b2eaff7b8", - "reference": "d68dbdc53dc358a816f00b300704702b2eaff7b8", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "require-dev": { - "phpunit/phpunit": "~4.0" - }, - "suggest": { - "dflydev/markdown": "~1.0", - "erusev/parsedown": "~1.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0.x-dev" - } - }, - "autoload": { - "psr-0": { - "phpDocumentor": [ - "src/" - ] - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Mike van Riel", - "email": "mike.vanriel@naenius.com" - } - ], - "time": "2015-02-03T12:10:50+00:00" - }, - { - "name": "psr/log", - "version": "1.0.2", - "source": { - "type": "git", - "url": "https://github.com/php-fig/log.git", - "reference": "4ebe3a8bf773a19edfe0a84b6585ba3d401b724d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/4ebe3a8bf773a19edfe0a84b6585ba3d401b724d", - "reference": "4ebe3a8bf773a19edfe0a84b6585ba3d401b724d", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Log\\": "Psr/Log/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common interface for logging libraries", - "homepage": "https://github.com/php-fig/log", - "keywords": [ - "log", - "psr", - "psr-3" - ], - "time": "2016-10-10T12:19:37+00:00" - }, - { - "name": "psy/psysh", - "version": "v0.8.3", - "source": { - "type": "git", - "url": "https://github.com/bobthecow/psysh.git", - "reference": "1dd4bbbc64d71e7ec075ffe82b42d9e096dc8d5e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/bobthecow/psysh/zipball/1dd4bbbc64d71e7ec075ffe82b42d9e096dc8d5e", - "reference": "1dd4bbbc64d71e7ec075ffe82b42d9e096dc8d5e", - "shasum": "" - }, - "require": { - "dnoegel/php-xdg-base-dir": "0.1", - "jakub-onderka/php-console-highlighter": "0.3.*", - "nikic/php-parser": "~1.3|~2.0|~3.0", - "php": ">=5.3.9", - "symfony/console": "~2.3.10|^2.4.2|~3.0", - "symfony/var-dumper": "~2.7|~3.0" - }, - "require-dev": { - "friendsofphp/php-cs-fixer": "~1.11", - "hoa/console": "~3.16|~1.14", - "phpunit/phpunit": "~4.4|~5.0", - "symfony/finder": "~2.1|~3.0" - }, - "suggest": { - "ext-pcntl": "Enabling the PCNTL extension makes PsySH a lot happier :)", - "ext-pdo-sqlite": "The doc command requires SQLite to work.", - "ext-posix": "If you have PCNTL, you'll want the POSIX extension as well.", - "ext-readline": "Enables support for arrow-key history navigation, and showing and manipulating command history.", - "hoa/console": "A pure PHP readline implementation. You'll want this if your PHP install doesn't already support readline or libedit." - }, - "bin": [ - "bin/psysh" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-develop": "0.9.x-dev" - } - }, - "autoload": { - "files": [ - "src/Psy/functions.php" - ], - "psr-4": { - "Psy\\": "src/Psy/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Justin Hileman", - "email": "justin@justinhileman.info", - "homepage": "http://justinhileman.com" - } - ], - "description": "An interactive shell for modern PHP.", - "homepage": "http://psysh.org", - "keywords": [ - "REPL", - "console", - "interactive", - "shell" - ], - "time": "2017-03-19T21:40:44+00:00" - }, - { - "name": "squizlabs/php_codesniffer", - "version": "2.8.1", - "source": { - "type": "git", - "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "d7cf0d894e8aa4c73712ee4a331cc1eaa37cdc7d" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/d7cf0d894e8aa4c73712ee4a331cc1eaa37cdc7d", - "reference": "d7cf0d894e8aa4c73712ee4a331cc1eaa37cdc7d", - "shasum": "" - }, - "require": { - "ext-simplexml": "*", - "ext-tokenizer": "*", - "ext-xmlwriter": "*", - "php": ">=5.1.2" - }, - "require-dev": { - "phpunit/phpunit": "~4.0" - }, - "bin": [ - "scripts/phpcs", - "scripts/phpcbf" - ], - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.x-dev" - } - }, - "autoload": { - "classmap": [ - "CodeSniffer.php", - "CodeSniffer/CLI.php", - "CodeSniffer/Exception.php", - "CodeSniffer/File.php", - "CodeSniffer/Fixer.php", - "CodeSniffer/Report.php", - "CodeSniffer/Reporting.php", - "CodeSniffer/Sniff.php", - "CodeSniffer/Tokens.php", - "CodeSniffer/Reports/", - "CodeSniffer/Tokenizers/", - "CodeSniffer/DocGenerators/", - "CodeSniffer/Standards/AbstractPatternSniff.php", - "CodeSniffer/Standards/AbstractScopeSniff.php", - "CodeSniffer/Standards/AbstractVariableSniff.php", - "CodeSniffer/Standards/IncorrectPatternException.php", - "CodeSniffer/Standards/Generic/Sniffs/", - "CodeSniffer/Standards/MySource/Sniffs/", - "CodeSniffer/Standards/PEAR/Sniffs/", - "CodeSniffer/Standards/PSR1/Sniffs/", - "CodeSniffer/Standards/PSR2/Sniffs/", - "CodeSniffer/Standards/Squiz/Sniffs/", - "CodeSniffer/Standards/Zend/Sniffs/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "authors": [ - { - "name": "Greg Sherwood", - "role": "lead" - } - ], - "description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.", - "homepage": "http://www.squizlabs.com/php-codesniffer", - "keywords": [ - "phpcs", - "standards" - ], - "time": "2017-03-01T22:17:45+00:00" - }, - { - "name": "symfony/console", - "version": "v2.8.19", - "source": { - "type": "git", - "url": "https://github.com/symfony/console.git", - "reference": "86407ff20855a5eaa2a7219bd815e9c40a88633e" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/86407ff20855a5eaa2a7219bd815e9c40a88633e", - "reference": "86407ff20855a5eaa2a7219bd815e9c40a88633e", - "shasum": "" - }, - "require": { - "php": ">=5.3.9", - "symfony/debug": "^2.7.2|~3.0.0", - "symfony/polyfill-mbstring": "~1.0" - }, - "require-dev": { - "psr/log": "~1.0", - "symfony/event-dispatcher": "~2.1|~3.0.0", - "symfony/process": "~2.1|~3.0.0" - }, - "suggest": { - "psr/log": "For using the console logger", - "symfony/event-dispatcher": "", - "symfony/process": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.8-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Console\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Console Component", - "homepage": "https://symfony.com", - "time": "2017-04-03T20:37:06+00:00" - }, - { - "name": "symfony/debug", - "version": "v3.0.9", - "source": { - "type": "git", - "url": "https://github.com/symfony/debug.git", - "reference": "697c527acd9ea1b2d3efac34d9806bf255278b0a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/debug/zipball/697c527acd9ea1b2d3efac34d9806bf255278b0a", - "reference": "697c527acd9ea1b2d3efac34d9806bf255278b0a", - "shasum": "" - }, - "require": { - "php": ">=5.5.9", - "psr/log": "~1.0" - }, - "conflict": { - "symfony/http-kernel": ">=2.3,<2.3.24|~2.4.0|>=2.5,<2.5.9|>=2.6,<2.6.2" - }, - "require-dev": { - "symfony/class-loader": "~2.8|~3.0", - "symfony/http-kernel": "~2.8|~3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "3.0-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Debug\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Debug Component", - "homepage": "https://symfony.com", - "time": "2016-07-30T07:22:48+00:00" - }, - { - "name": "symfony/event-dispatcher", - "version": "v2.8.19", - "source": { - "type": "git", - "url": "https://github.com/symfony/event-dispatcher.git", - "reference": "88b65f0ac25355090e524aba4ceb066025df8bd2" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/88b65f0ac25355090e524aba4ceb066025df8bd2", - "reference": "88b65f0ac25355090e524aba4ceb066025df8bd2", - "shasum": "" - }, - "require": { - "php": ">=5.3.9" - }, - "require-dev": { - "psr/log": "~1.0", - "symfony/config": "^2.0.5|~3.0.0", - "symfony/dependency-injection": "~2.6|~3.0.0", - "symfony/expression-language": "~2.6|~3.0.0", - "symfony/stopwatch": "~2.3|~3.0.0" - }, - "suggest": { - "symfony/dependency-injection": "", - "symfony/http-kernel": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.8-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\EventDispatcher\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony EventDispatcher Component", - "homepage": "https://symfony.com", - "time": "2017-04-03T20:37:06+00:00" - }, - { - "name": "symfony/finder", - "version": "v2.8.19", - "source": { - "type": "git", - "url": "https://github.com/symfony/finder.git", - "reference": "7131327eb95d86d72039fd1216226c28f36fd02a" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/finder/zipball/7131327eb95d86d72039fd1216226c28f36fd02a", - "reference": "7131327eb95d86d72039fd1216226c28f36fd02a", - "shasum": "" - }, - "require": { - "php": ">=5.3.9" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.8-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Finder\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Finder Component", - "homepage": "https://symfony.com", - "time": "2017-03-20T08:46:40+00:00" - }, - { - "name": "symfony/polyfill-mbstring", - "version": "v1.3.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "e79d363049d1c2128f133a2667e4f4190904f7f4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/e79d363049d1c2128f133a2667e4f4190904f7f4", - "reference": "e79d363049d1c2128f133a2667e4f4190904f7f4", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "suggest": { - "ext-mbstring": "For best performance" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Mbstring\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill for the Mbstring extension", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "mbstring", - "polyfill", - "portable", - "shim" - ], - "time": "2016-11-14T01:06:16+00:00" - }, - { - "name": "symfony/var-dumper", - "version": "v2.8.19", - "source": { - "type": "git", - "url": "https://github.com/symfony/var-dumper.git", - "reference": "f8ff23ad5352f96e66c1df5468d492d2f37f3ac4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/var-dumper/zipball/f8ff23ad5352f96e66c1df5468d492d2f37f3ac4", - "reference": "f8ff23ad5352f96e66c1df5468d492d2f37f3ac4", - "shasum": "" - }, - "require": { - "php": ">=5.3.9", - "symfony/polyfill-mbstring": "~1.0" - }, - "conflict": { - "phpunit/phpunit": "<4.8.35|<5.4.3,>=5.0" - }, - "require-dev": { - "twig/twig": "~1.20|~2.0" - }, - "suggest": { - "ext-symfony_debug": "" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.8-dev" - } - }, - "autoload": { - "files": [ - "Resources/functions/dump.php" - ], - "psr-4": { - "Symfony\\Component\\VarDumper\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony mechanism for exploring and dumping PHP variables", - "homepage": "https://symfony.com", - "keywords": [ - "debug", - "dump" - ], - "time": "2017-03-12T16:01:59+00:00" - }, - { - "name": "symfony/yaml", - "version": "v2.8.19", - "source": { - "type": "git", - "url": "https://github.com/symfony/yaml.git", - "reference": "286d84891690b0e2515874717e49360d1c98a703" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/286d84891690b0e2515874717e49360d1c98a703", - "reference": "286d84891690b0e2515874717e49360d1c98a703", - "shasum": "" - }, - "require": { - "php": ">=5.3.9" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.8-dev" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Component\\Yaml\\": "" - }, - "exclude-from-classmap": [ - "/Tests/" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Fabien Potencier", - "email": "fabien@symfony.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony Yaml Component", - "homepage": "https://symfony.com", - "time": "2017-03-20T09:41:44+00:00" - }, - { - "name": "webmozart/assert", - "version": "1.2.0", - "source": { - "type": "git", - "url": "https://github.com/webmozart/assert.git", - "reference": "2db61e59ff05fe5126d152bd0655c9ea113e550f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/webmozart/assert/zipball/2db61e59ff05fe5126d152bd0655c9ea113e550f", - "reference": "2db61e59ff05fe5126d152bd0655c9ea113e550f", - "shasum": "" - }, - "require": { - "php": "^5.3.3 || ^7.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.6", - "sebastian/version": "^1.0.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3-dev" - } - }, - "autoload": { - "psr-4": { - "Webmozart\\Assert\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Bernhard Schussek", - "email": "bschussek@gmail.com" - } - ], - "description": "Assertions to validate method input/output with nice error messages.", - "keywords": [ - "assert", - "check", - "validate" - ], - "time": "2016-11-23T20:04:58+00:00" - }, - { - "name": "webmozart/path-util", - "version": "2.3.0", - "source": { - "type": "git", - "url": "https://github.com/webmozart/path-util.git", - "reference": "d939f7edc24c9a1bb9c0dee5cb05d8e859490725" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/webmozart/path-util/zipball/d939f7edc24c9a1bb9c0dee5cb05d8e859490725", - "reference": "d939f7edc24c9a1bb9c0dee5cb05d8e859490725", - "shasum": "" - }, - "require": { - "php": ">=5.3.3", - "webmozart/assert": "~1.0" - }, - "require-dev": { - "phpunit/phpunit": "^4.6", - "sebastian/version": "^1.0.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.3-dev" - } - }, - "autoload": { - "psr-4": { - "Webmozart\\PathUtil\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Bernhard Schussek", - "email": "bschussek@gmail.com" - } - ], - "description": "A robust cross-platform utility for normalizing, comparing and modifying file paths.", - "time": "2015-12-17T08:42:14+00:00" - } - ], - "packages-dev": [], - "aliases": [], - "minimum-stability": "dev", - "stability-flags": [], - "prefer-stable": true, - "prefer-lowest": false, - "platform": [], - "platform-dev": [] -} diff --git a/docker-compose.linux.yml b/docker-compose.linux.yml new file mode 100644 index 0000000000..3af569422b --- /dev/null +++ b/docker-compose.linux.yml @@ -0,0 +1,38 @@ +version: "3" + +services: + app: + image: previousnext/php:7.2-dev + # This makes the container run on the same network stack as your + # workstation. Meaning that you can interact on "localhost". + network_mode: host + volumes: + - .:/data + environment: + - SIMPLETEST_BASE_URL=http://127.0.0.1 + - SIMPLETEST_DB=mysql://drupal:drupal@127.0.0.1/local + - BROWSERTEST_OUTPUT_DIRECTORY=/data/app/sites/simpletest/browser_output + - MINK_DRIVER_ARGS= + - MINK_DRIVER_ARGS_WEBDRIVER=["chrome", null, "http:\/\/127.0.0.1:4444\/wd\/hub"] + - PHP_IDE_CONFIG=serverName=127.0.0.1 + - PHP_XDEBUG_AUTOSTART=1 + - XDEBUG_CONFIG=remote_host=127.0.0.1 + - PATH=$PATH:/data/bin:/data/app/vendor/bin + - DRUSH_OPTIONS_URI=http://127.0.0.1 + + db: + image: mariadb + network_mode: host + environment: + - MYSQL_ROOT_PASSWORD=root + - MYSQL_DATABASE=local + - MYSQL_USER=drupal + - MYSQL_PASSWORD=drupal + + mail: + image: mailhog/mailhog + network_mode: host + + chrome: + image: selenium/standalone-chrome + network_mode: host diff --git a/docker-compose.osx.yml b/docker-compose.osx.yml new file mode 100644 index 0000000000..5a2291107d --- /dev/null +++ b/docker-compose.osx.yml @@ -0,0 +1,51 @@ +version: "3" + +services: + app: + image: previousnext/php:7.2-dev + # You will notice that we are forwarding port which do not belong to PHP. + # We have to declare them here because these "sidecar" services are sharing + # THIS containers network stack. + ports: + - "80:80" + - "3306:3306" + - "8983:8983" + - "8025:8025" + - "8910:8910" + - "9222:9222" + volumes: + - .:/data:cached + environment: + - SIMPLETEST_BASE_URL=http://127.0.0.1 + - SIMPLETEST_DB=mysql://drupal:drupal@127.0.0.1/local + - BROWSERTEST_OUTPUT_DIRECTORY=/data/app/sites/simpletest/browser_output + - MINK_DRIVER_ARGS= + - MINK_DRIVER_ARGS_WEBDRIVER=["chrome", null, "http:\/\/127.0.0.1:4444\/wd\/hub"] + - PHP_IDE_CONFIG=serverName=127.0.0.1 + - PHP_XDEBUG_AUTOSTART=1 + - XDEBUG_CONFIG=remote_host=127.0.0.1 + - PATH=$PATH:/data/bin:/data/app/vendor/bin + - DRUSH_OPTIONS_URI=http://127.0.0.1 + + xdebug: + image: nickschuch/d4m-tcp-forwarder + network_mode: host + environment: + - PORT=9000 + + db: + image: mariadb + network_mode: service:php + environment: + - MYSQL_ROOT_PASSWORD=root + - MYSQL_DATABASE=local + - MYSQL_USER=drupal + - MYSQL_PASSWORD=drupal + + mail: + image: mailhog/mailhog + network_mode: service:php + + chrome: + image: selenium/standalone-chrome + network_mode: service:app diff --git a/docs/vm-docker.md b/docs/vm-docker.md new file mode 100755 index 0000000000..1a063a9c0f --- /dev/null +++ b/docs/vm-docker.md @@ -0,0 +1,68 @@ +## Docker for local development + +In order to use Docker for local development, you will need Docker for Mac Beta 17.05 or above from the [Edge Channel][1]. This version supports the cached volume strategy which makes performance for Drupal acceptable. + +### Bash Aliases + +The docker-compose files are split based on operating system. + +This allows us to do cool things on a "per OS" basis eg. `network_mode: host` for Linux. + +Add the following to our bash alias. + +**OSX** + +```bash +alias dc='docker-compose -f docker-compose.osx.yml' +``` + +**Linux** + +```bash +alias dc='docker-compose -f docker-compose.linux.yml' +``` + +### Running + +You can spin up a local environment with the following command: + +```bash +$ dc up -d +``` + +Then enter that container with: + +```bash +$ dc exec php bash +``` + +### Drupal settings + +In order to have the correct db and mailhost host settings you will need to copy `app/sites/default/default.settings.local.docker.php` to `app/sites/default/settings.local.docker.php` + +### Browsing the site + +The docker site will be avaiable on [http://127.0.0.1/](http://127.0.0.1/) + +You can only have one project running at a time. + +[1]: https://docs.docker.com/docker-for-mac/install/ + +### Xdebug + +**From the browser** + +This will work automatically due to the service "xdebug" declared in the docker-composer.yaml. + +This will take all xdebug traffic and forward it onto your OSX laptop. + +**From the CLI** + +Given xdebug is provided no context of which host to send its xdebug data to, you will need to +set the following configuration on the CLI before running + +```bash +export PHP_IDE_CONFIG="serverName=localhost";export XDEBUG_CONFIG="remote_host=192.168.65.1"; +``` + +The IP address 192.168.65.1 is common amongst all Docker for Mac installations diff --git a/provision.sh b/provision.sh deleted file mode 100644 index ae67c2f3cc..0000000000 --- a/provision.sh +++ /dev/null @@ -1,3 +0,0 @@ -#!/bin/bash - -switch_php 7.1