Variables

The following variables can be set in Vlad's settings file.

Webserver

webserver_hostname

The hostname of the site you are about to create. By default this is then combined with the variable webserver_hostname_alias to add 'www' to the start.

default value: 'drupal.local'

webserver_hostname_aliases

In order to support multiple projects, or Drupal multi-site installations, this lets you add a list of fully qualified names for your web server aliases.

default value: - 'www.drupal.local'

Vagrantfile configuration

boxipaddress

The IP address of the virtual machine.

default value: "192.168.100.100"

boxname

The name of the box that will be used by Vagrant to label the box inside your virtual machine manager of choice. This value should only contain letters, numbers, hyphens or dots. The VM will appear as boxname + "_vlad" in your chosen virtual machine manager.

default value: "vlad"

vlad_os

The OS that vlad will use. This can be one of the following:

  • "centos65"
  • "ubuntu12"
  • "ubuntu14"

default value: "ubuntu14"

host_synced_folder

This is the directory that will be used to server the files from. If this doesn't exist then it will be created.

default value: "./docroot"

aux_synced_folder

This is a secondary Vagrant synced folder used to sync files that don't belong in host_synced_folder. If this doesn't exist then it will be created.

default value: "./vlad_aux"

synced_folder_type

Only applicable for when running VLAD on a non-Windows host. Use 'nfs' or 'rsync' for VM file editing in synced folder.

default value: 'nfs'

ansible_verbosity

Set the level of verbosity that Ansible will use. This can be one of "", "v", "vv", "vvv", or "vvvv".

default value: ""

vm_cpus

Number of CPU cores to be allocated to the guest VM from the host machine. This can be an integer or can be set to "auto" for Vlad to automatically assign all available cores.

default value: '2'

vm_memory

Amount of memory to be allocated to the guest VM from the host machine. This can be an integer (MB) or can be set to "auto" for Vlad to automatically assign 1/4 of host machine's memory.

default value: '1024'

parallels_update_guest_tools

Whether the vagrant-parallels plugin should update the Guest Tools in the VM automatically.

default value: false

Components to install

The server components that will be installed when the box is provisioned.

  • To install a component set it to true.
  • To leave a component out of the install set the value to false.

adminer_install

Installs Adminer.

default value: true

apache_install

Installs Apache server.

default value: true

bling_install

Adds bling.

default value: true

imagemagick_install

Installs Imagemagick as well as the PHP extension.

default value: false

mailcatcher_install

Installs Mailcatcher. Also installs the Ruby task as a dependency.

default value: false

memcached_install

Installs Memcache as well as the PHP extension.

default value: false

munin_install

Installs Munin server.

default value: false

mysql_install

Installs MySQL.

default value: true

node_install

Installs Node.

default value: false

php_install

Installs PHP, including a number of PHP packages as well as APC, Composer, and Xdebug.

default value: true

pimpmylog_install

Installs PimpMyLog.

default value: false

redis_install

Installs Redis.

default value: false

ruby_install

Installs Ruby. Ruby is required by MailCatcher.

default value: false

sendmail_install

Installs the Sendmail server.

default value: false

solr_install

Installs Tomcat 6 and Solr 4.

default value: false

varnish_install

Installs Varnish. Vlad will run checks to ensure that varnish can listen on port 80 and that Apache doesn't clash with that port.

default value: false

xhprof_install

Installs Xhprof and a Xhprof GUI.

default value: false

Provision with custom role

custom_provision

Run a custom role as part of provisioning. See Custom roles for more information.

default value: false

HTTP ports

http_port

HTTP port for the web server. If you have opted to install Varnish you will likely want to change this to 8080.

default value: 80

varnish_http_port

HTTP port for the Varnish cache.

default value: 80

Administration email

admin_mail

Used in instances when a server email is needed.

default value: 'test@example.com'

PHP

php_version

The version of PHP to install (dependent on OS). Can be one of:

  • "5.3"
  • "5.4"
  • "5.5"
  • "5.6"

Note that Ubuntu 14 won't install < PHP5.4 so you'll get PHP5.5+. Vlad will error when a version that isn't understood is used.

default value: "5.5"

php.ini

php_memory_limit

default value: 512M

php_max_execution_time

default value: 60

php_post_max_size

default value: 100M

php_upload_max_filesize

default value: 100M

php_display_errors

default value: On

php_display_startup_errors

default value: On

php_html_errors

default value: On

php_date_timezone

default value: Europe/London

Install PECL uploadprogress

php_pecl_uploadprogress

default value: false

PHP APC

apc_rfc1867

default value: '1'

apc_shm_size

default value: '256M'

apc_shm_segments

default value: '1'

apc_num_files_hint

default value: '0'

MySQL

mysql_port

default value: 3306

mysql_root_password

default value: sdfds87643y5thgfd

server_hostname

default value: vlad

dbname

This is a list of databases that Vlad will generate. As a default a single database is created but this value can be changed to make Vlad add more databases. The following setting will generate two databases, one called 'database1' and the other called 'database2'.

dbname: ['database1', 'database2']

Each database has the same access privileges.

It should be noted that the first database in this list is always used as the default database. This database is used by Vlad when running automatic actions such as exporting or importing the database.

default value: ['vladdb']

dbuser

The user that will be created for the databases.

default value: vlad

dbpass

The password for the database user.

default value: wibble

db_import_up

Import MySQL databases from files on 'vagrant up'.

Database import won't occur if the first present database has any tables defined (in order to prevent data loss).

Options include:

  • false - don't import anything
  • true - import from files within vlad_aux/db_io/halt_destroy/ - source filenames will need to correspond with values in dbname.
  • ["path_to_file","path_to_file"] - import from vlad_aux/db_io/[path_to_file]. Requires an entry for each database specified in dbname. Supports .sql, .bz2 and .gz files.

default value: false

MySQL my.cnf

mysql_max_allowed_packet

default value: 128M

innodb_buffer_pool_size

default value: 64M

innodb_file_per_table

default value: true

innodb_log_file_size

default value: 64M

mysql_character_set_server

default value: utf8

mysql_collation_server

default value: utf8_general_ci

skip_name_resolve

default value: true

mysql_hosts

A list of hosts that MySQL should map to databases to allow access.

default value: ['{{ local_ipv4_address.ansible_facts.ansible_default_ipv4.address }}', '127.0.0.1', 'localhost']

mysql_allow_all_hosts

Whether to allow all hosts (0.0.0.0) or a specific IP address (which is taken from the boxipaddress variable) default value: true

SSH

ssh_port

default value: 22

use_host_id

Add RSA or DSA identity from host to guest on 'vagrant up'. Does not support identites that require a passphrase.

Options include:

  • false : don't add anything
  • true : add default files (~/.ssh/id_rsa, ~/.ssh/id_dsa & ~/.ssh/identity)
  • "[filename]" : add a specific file e.g. /Users/username/.ssh/[filename]

default value: false

Varnish

varnish_memory

Sets the amount of memory that Varnish can use (in Megabytes).

default value: 512

Redis

redis_port

Sets the port Redis should listen on.

default value: 6379

Drush make

drush_make_file

The name of the make file that is to be run. Vlad expects this file to be placed in a subdirectory called "make" within your vlad_aux directory.

E.g. "vlad_example_d7.make"

Drush make will not be run if no file is specified.

default value: ""

drush_make_options

Options to pass to drush make command.

E.g. "--prepare-install"

See http://www.drushcommands.com/drush-6x/make/make for possible options.

default value: ""

drush_make_force

Run drush make every time the VM is provisioned. Setting to false will only run drush make if a make file has been specified and docroot does not contain an existing Drupal codebase.

default value: false

drush_structure_tables

Sets the tables to be skipped in the "$options['structure-tables']['common']" config variable in the .drushrc.php file. Allows you to run drush database dump commands using the --structure-tables-key parameter to skip certain table data like caches and session data. For example, to export the database and skip those tables you would run the following command.

drush sql-dump --structure-tables-key=common --gzip --result-file=dump.sql

default value: "['cache','cache_filter','cache_menu','cache_page','history','sessions','watchdog','cache_admin_menu','cache_block','cache_field','cache_form','cache_path','cache_token','cache_update','cache_views','cache_views_data','ctools_css_cache','ctools_object_cache','search_dataset','search_index','search_node_links','search_total']"

Bling

bling_shell_prompt

Tweaks shell prompt.

default value: true

Other settings

drupal_solr_package

Select which Solr module to install accepted values are 'search_api_solr' or 'apachesolr'

default value: "search_api_solr"

hosts_file_location

Local hosts file location.

Default location on *nix hosts is '/etc/hosts'.

Default location for GasMask on OSX is '/Users/< username >/Library/Gas Mask/Local/< file >.hst'.

default value: "/etc/hosts"

hosts_file_update

Select whether Vlad should edit the hosts file.

default value: true

add_index_file

Add the default index.php file (useful to turn off if you are going git clone into the web root folder). Vlad will also not overwrite any existing index.php file present in the docroot location.

default value: true

drush_aliases_assemble

Drush alias files can be placed in either of Vlad's settings directories. See http://vlad-docs.readthedocs.org/en/latest/usage/settings_file

Setting to true will assemble all alias/aliases files into a single group aliases file prefixed with the boxname.

Setting to false will copy alias/aliases files to the guest without assembling or renaming.

default value: false

Git config user credentials

Leave these variables empty to skip this step.

git_user_name

Your git username.

default value: ""

git_user_email

Your git email address.

default value: ""