Switch to containerized environment for Travis CI

Original (virtualized) environment led to a test failure not
reproducible in development. Containerized CI builds permit debugging
and troubleshooting on local development machines via Docker.
This commit is contained in:
Ryan Lue 2018-03-24 23:06:18 +08:00
parent 307ce2f506
commit 5f66ac73b2

View file

@ -1,6 +1,5 @@
dist: trusty
sudo: required
group: deprecated
sudo: false
notifications:
email:
- me+tv@zammad.com
@ -11,6 +10,31 @@ addons:
postgresql: "9.4"
apt:
packages:
- curl
- git-core
- patch
- build-essential
- bison
- zlib1g-dev
- libssl-dev
- libxml2-dev
- sqlite3
- libsqlite3-dev
- autotools-dev
- libxslt1-dev
- libyaml-0-2
- autoconf
- automake
- libreadline6-dev
- libyaml-dev
- libtool
- libgmp-dev
- libgdbm-dev
- libncurses5-dev
- pkg-config
- libffi-dev
- libmysqlclient-dev
- postfix
- mysql-server-5.6
- mysql-client-core-5.6
- mysql-client-5.6
@ -22,8 +46,6 @@ rvm:
- 2.4.2
before_install:
- git fetch --unshallow
- sudo apt-get -qq update
- sudo apt-get install -y curl git-core patch build-essential bison zlib1g-dev libssl-dev libxml2-dev libxml2-dev sqlite3 libsqlite3-dev autotools-dev libxslt1-dev libyaml-0-2 autoconf automake libreadline6-dev libyaml-dev libtool libgmp-dev libgdbm-dev libncurses5-dev pkg-config libffi-dev libmysqlclient-dev postfix
- if [ "${DB}" = "mysql" ]; then mysql -u root -e "CREATE USER 'some_user'@'localhost' IDENTIFIED BY 'some_pass';"; fi
- if [ "${DB}" = "mysql" ]; then mysql -u root -e "GRANT ALL PRIVILEGES ON *.* TO 'some_user'@'localhost';"; fi
- if [ "${DB}" = "mysql" ]; then cp config/database.yml.test-mysql config/database.yml; fi