lammensj/resilient-vm

Project template for Resilient distributions inside DrupalVM.

1.0.2 2018-01-05 15:01 UTC

This package is auto-updated.

Last update: 2024-10-15 20:18:27 UTC


README

[Project name]

[Project description]

Getting Started

These instructions will get you a Drupal 8 project up and running on your local machine for development and testing purposes.

Prerequisites

All you need is Composer and Vagrant installed on your laptop or pc. Every other service will be downloaded inside the virtual machine.

$ composer install

Installing

Default settings regarding the VM can be found in ./config. The following files are present:

  • config.yml: configuration independent of the project (eg. synced folders, ports, composer etc.)
  • default.local.config.yml: configuration about the project (eg. name, credentials etc.)
$ cp ./config/default.local.config.yml ./config/local.config.yml

Adjust the lines in ./config/local.config.yml which are not commented to match your project.

A. Starting fresh

Uncomment the lines below # Installing from scratch in ./config/local.config.yml.

B. Starting from existing configuration

Uncomment the lines below # Installing from existing configuration in ./config/local.config.yml.

Run Vagrant

All there is left to do, is start Vagrant and let it do its thing.

$ DRUPALVM_ANSIBLE_ARGS='--extra-vars "drupal_install_site=true"' vagrant up

This will download a Vagrant machine (Debian9) and provision it using Ansible. Inside, a Resilient-distribution will be installed. If everything is finished, go to the url you set up in ./config/local.config.yml under vagrant_hostname.

Credentials

Connecting to MySQL

  • MySQL Host: 127.0.0.1
  • Username: drupal (unless overridden by drupal_db_user)
  • Password: drupal (unless overridden by drupal_db_password)
  • SSH Host: 192.168.88.88 (unless overridden by vagrant_ip)
  • SSH User: vagrant (unless overridden by vagrant_user)
  • SSH Key: (browse to your ~/.vagrant.d/ folder and choose insecure_private_key)

Drupal

  • Username: admin (unless overridden by drupal_account_name)
  • Password: the default is admin but please change this when going to production (unless overridden by drupal_account_pass)

Built With

Workflow

Config management

Hence the fact that we're using Config Split to break apart certain config (eg. only enable Devel in development) we must use the drush commands provided by that module. Use $ drush csex -y to export and $ drush csim -y to import configuration files. You can enable development config by adding $config['config_split.config_split.dev']['status'] = TRUE; in ./htdocs/web/sites/default/settings.local.php.

Versioning

We use Gitflow for versioning.

Authors

  • Jasper Lammens - Initial work - lammensj

License

This project is licensed under the MIT License - see the LICENSE file for details.