A utility to install Microsoft ODBC drivers and PHP modules for Microsoft SQL Server as part of provisioning in VVV.
This package hooks into the VVV utilities system to install the Microsoft ODBC driver for Ubuntu 18.04 and the PHP modules for Microsoft SQL Server at the system level. It will install the appropriate PHP modules for all versions of PHP => 7.0 active in the VVV core utilities section (in addition to the default PHP version).
System requirements warning: This utility requires VVV 3.0 or greater. At present it needs least Ubuntu 16.04 LTS (Xenial) to work correctly (due to problems encountered with the Microsoft drivers and unixodbc
package on Ubunut < 16.04). VVV prior to version 3.0 installed Ubuntu 14.04 LTS (Trusty) but since 3.0 uses 18.04 (Bionic).
Installation happens automatically during site provisioning. Add the following to your vvv-custom.yml
configuration file and then reprovision (vagrant up --provision
or vagrant reload --provision
).
utilities:
odbc:
- msodbcsql17 # MS SQL server ODBC libraries
- sqlsrv # MS SQL PHP drivers
utility-sources:
odbc: https://github.com/admturner/vvv-odbc-utilities.git
Your final "utilities" list may look something like this:
utilities:
core: # The core VVV utility
- php73
- memcached-admin # Object cache management
- opcache-status # opcache management
- phpmyadmin # Web based database client
- webgrind # PHP Debugging
- tls-ca # SSL/TLS certificates
- mongodb # needed for Tideways/XHGui
- tideways # PHP profiling tool
odbc:
- msodbcsql17 # MS SQL server ODBC libraries
- sqlsrv # PHP SQL server extensions
utility-sources:
odbc: https://github.com/admturner/vvv-odbc-utilities.git
This configuration would install the default VVV PHP version (currently 7.2) as well as PHP 7.3. VVV ODBC Utility would then install the Microsoft ODBC Driver 17 and dependencies and would then install and configure the sqlsrv
and pdo_sqlsrv
PHP modules for PHP 7.2 and 7.3.
For more see the official VVV documentation on utilities.
unixodbc-dev
(ODBC libraries for UNIX, development files)msodbcsql17
(Microsoft ODBC Driver 17 for SQL Server)
Installing the above will also install dependencies.
sqlsrv
PHP SQLSRV extensionpdo_sqlsrv
PHP PDO_SQLSRV extension