├── .gitignore ├── .travis.yml ├── LICENSE ├── README.md ├── Vagrantfile ├── docs ├── deployment │ ├── drush-make.md │ ├── local-codebase.md │ └── multisite.md ├── extras │ ├── behat.md │ ├── drupal-console.md │ ├── drush.md │ ├── mailhog.md │ ├── mariadb.md │ ├── mysql.md │ ├── nodejs.md │ ├── pimpmylog.md │ ├── scripts.md │ ├── solr.md │ ├── ssl.md │ ├── syncing-folders.md │ ├── varnish.md │ ├── xdebug.md │ └── xhprof.md ├── images │ └── drupal-vm-logo.png ├── index.md └── other │ ├── base-os.md │ ├── bigpipe.md │ ├── drupal-6.md │ ├── linux.md │ ├── local-vagrantfile.md │ ├── management-tools.md │ ├── networking.md │ ├── php-7.md │ ├── vagrant-virtualbox.md │ ├── webservers.md │ └── windows.md ├── example.config.yml ├── example.drupal.make.yml ├── examples ├── acquia │ ├── README.md │ └── acquia.overrides.yml ├── prod │ ├── README.md │ ├── bootstrap │ │ ├── example.vars.yml │ │ └── init.yml │ ├── example.inventory │ └── prod.overrides.yml └── scripts │ ├── README.md │ └── configure-solr.sh ├── mkdocs.yml ├── provisioning ├── JJG-Ansible-Windows │ ├── LICENSE │ ├── README.md │ └── windows.sh ├── playbook.yml ├── requirements.yml ├── tasks │ ├── apparmor.yml │ ├── build-makefile.yml │ ├── cron.yml │ ├── dashboard.yml │ ├── drush-aliases.yml │ ├── extras.yml │ ├── init-debian.yml │ ├── init-redhat.yml │ ├── install-site.yml │ ├── sshd.yml │ └── www.yml ├── templates │ ├── dashboard.html.j2 │ ├── drupalvm-local.aliases.drushrc.php.j2 │ ├── drupalvm.aliases.drushrc.php.j2 │ ├── drupalvm.vcl.j2 │ └── nginx-vhost.conf.j2 └── vars │ └── main.yml └── tests ├── Dockerfile.centos-7 ├── Dockerfile.ubuntu-14.04 ├── centos-7-vars.yml ├── initctl_faker ├── test-vars.yml └── ubuntu-14-nginx.yml /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | .idea/ 3 | .project/ 4 | .vagrant/ 5 | .bundle/ 6 | *.retry 7 | vagrant_ansible_inventory_default 8 | config.yml 9 | drupal.make.yml 10 | Vagrantfile.local 11 | examples/prod/inventory 12 | examples/prod/bootstrap/vars.yml 13 | scripts/ 14 | roles/ 15 | drupal/ 16 | -------------------------------------------------------------------------------- /.travis.yml: -------------------------------------------------------------------------------- 1 | --- 2 | sudo: required 3 | 4 | env: 5 | global: 6 | - CONFIG: example.config.yml 7 | MAKEFILE: example.drupal.make.yml 8 | HOSTNAME: drupalvm.dev 9 | MACHINE_NAME: drupalvm 10 | IP: 192.168.88.88 11 | matrix: 12 | - distribution: ubuntu 13 | version: 14.04 14 | init: /sbin/init 15 | run_opts: "--privileged" 16 | - distribution: ubuntu 17 | version: 14.04 18 | init: /sbin/init 19 | run_opts: "--privileged" 20 | additional_vars: ubuntu-14-nginx.yml 21 | - distribution: centos 22 | version: 7 23 | init: /usr/lib/systemd/systemd 24 | run_opts: "--privileged --volume=/sys/fs/cgroup:/sys/fs/cgroup:ro" 25 | additional_vars: "centos-7-vars.yml" 26 | 27 | services: 28 | - docker 29 | 30 | before_install: 31 | # Pull container 32 | - 'sudo docker pull ${distribution}:${version}' 33 | # Customize container 34 | - 'sudo docker build --rm=true --file=tests/Dockerfile.${distribution}-${version} --tag=${distribution}-${version}:ansible tests' 35 | # Install lint tools. 36 | - 'gem install rubocop' 37 | 38 | script: 39 | - container_id=$(mktemp) 40 | 41 | # Run container in detached state 42 | - 'sudo docker run --detach --volume="${PWD}":/var/www/drupalvm/:rw ${run_opts} ${distribution}-${version}:ansible "${init}" > "${container_id}"' 43 | 44 | # Set hostname. 45 | - 'sudo docker exec "$(cat ${container_id})" hostname ${HOSTNAME}' 46 | 47 | # Setup directories. 48 | - 'sudo docker exec "$(cat ${container_id})" mkdir -p /var/www/drupalvm/drupal' 49 | 50 | # Install dependencies. 51 | - 'sudo docker exec "$(cat ${container_id})" ansible-galaxy install -r /var/www/drupalvm/provisioning/requirements.yml' 52 | 53 | # Copy configuration files into place. 54 | - 'sudo docker exec "$(cat ${container_id})" cp /var/www/drupalvm/$CONFIG /var/www/drupalvm/config.yml' 55 | - 'sudo docker exec "$(cat ${container_id})" cp /var/www/drupalvm/$MAKEFILE /var/www/drupalvm/drupal.make.yml' 56 | 57 | # Append additional variables. 58 | - 'sudo docker exec "$(cat ${container_id})" bash -c "cat /var/www/drupalvm/tests/test-vars.yml >> /var/www/drupalvm/config.yml" || true' 59 | - '[[ $additional_vars ]] && sudo docker exec "$(cat ${container_id})" bash -c "cat /var/www/drupalvm/tests/${additional_vars} >> /var/www/drupalvm/config.yml" || true' 60 | 61 | # Vagrantfile syntax check 62 | - 'rubocop --except LineLength,Eval,MutableConstant' 63 | 64 | # Ansible syntax check. 65 | - 'sudo docker exec --tty "$(cat ${container_id})" env TERM=xterm ansible-playbook /var/www/drupalvm/provisioning/playbook.yml --syntax-check' 66 | 67 | # Run the playbook with ansible-playbook. 68 | - 'sudo docker exec --tty "$(cat ${container_id})" env TERM=xterm ansible-playbook /var/www/drupalvm/provisioning/playbook.yml' 69 | 70 | # Run the integration tests 71 | - > 72 | sudo docker exec "$(cat ${container_id})" curl -s --header Host:${HOSTNAME} localhost 73 | | grep -q '
{{ docroot }}
drush @{{ vagrant_machine_name }}.{{ servername }}
Hostname | 92 |Document Root | 93 | {% if configure_local_drush_aliases -%} 94 |Drush alias* | 95 | {%- endif %} 96 |
---|---|---|
*Note: On Windows or when you don't have Ansible installed on your host, Drush aliases are only created inside the VM. |
Adminer | 119 |{{ servername() }} | 120 |121 | Open 122 | Documentation 123 | | 124 |
---|---|---|
MailHog | 132 |{{ servername() }} | 133 |134 | Open 135 | Documentation 136 | | 137 |
PimpMyLog | 145 |{{ servername() }} | 146 |147 | Open 148 | Documentation 149 | | 150 |
Solr | 157 |{{ servername() }} | 158 |159 | Open 160 | Documentation 161 | | 162 |
XHProf | 169 |{{ servername() }} | 170 |171 | Open 172 | Documentation 173 | | 174 |
MySQL Hostname | 184 |127.0.0.1 |
185 |
---|---|
MySQL Port | 188 |{{ mysql_port }} |
189 |
MySQL Username | 192 |{{ mysql_root_username }} |
193 |
MySQL Password | 196 |{{ mysql_root_password }} |
197 |
SSH Hostname | 200 |{{ vagrant_ip }} |
201 |
SSH Username | 204 |{{ vagrant_user }} |
205 |
SSH Private Key | 208 |~/.vagrant.d/insecure_private_key |
209 |
Database name | 218 | {% if 'adminer' in installed_extras -%} 219 |220 | {%- endif %} 221 | |
---|---|
{{ database.name }} |
227 | {% if 'adminer' in installed_extras -%}
228 | 229 | Adminer 230 | | 231 | {%- endif %} 232 |
Username | 243 |Password | 244 |
---|---|
{{ user.name }} |
250 | {{ user.password }} |
251 |
Drupal VM is a VM for local Drupal development, built with Vagrant + Ansible.
266 | 267 |