From 48c78920712a580534bd87fc4c7d48eb2994c03b Mon Sep 17 00:00:00 2001 From: mastertheknife Date: Tue, 1 Oct 2013 15:29:54 +0300 Subject: [PATCH] Another attempt to create the ZM database in travis --- .travis.yml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/.travis.yml b/.travis.yml index 2acbeb1d3..4197ff1ec 100644 --- a/.travis.yml +++ b/.travis.yml @@ -35,13 +35,14 @@ before_script: - if [ "$ZM_BUILDMETHOD" = "autotools" ]; then automake --force-missing --add-missing; fi - if [ "$ZM_BUILDMETHOD" = "autotools" ]; then autoconf; fi script: - - if [ "$ZM_BUILDMETHOD" = "autotools" ]; then ./configure --prefix=/usr --with-libarch=lib/$DEB_HOST_GNU_TYPE --host=$DEB_HOST_GNU_TYPE --build=$DEB_BUILD_GNU_TYPE --with-mysql=/usr --with-ffmpeg=/usr --with-webdir=/usr/share/zoneminder/www --with-cgidir=/usr/libexec/zoneminder/cgi-bin --with-webuser=www-data --with-webgroup=www-data --enable-crashtrace=yes --disable-debug --enable-mmap=yes ZM_SSL_LIB=openssl ZM_DB_USER="travis"; fi - - if [ "$ZM_BUILDMETHOD" = "cmake" ]; then cmake -DCMAKE_INSTALL_PREFIX="/usr" -DZM_DB_USER="travis"; fi + - if [ "$ZM_BUILDMETHOD" = "autotools" ]; then ./configure --prefix=/usr --with-libarch=lib/$DEB_HOST_GNU_TYPE --host=$DEB_HOST_GNU_TYPE --build=$DEB_BUILD_GNU_TYPE --with-mysql=/usr --with-ffmpeg=/usr --with-webdir=/usr/share/zoneminder/www --with-cgidir=/usr/libexec/zoneminder/cgi-bin --with-webuser=www-data --with-webgroup=www-data --enable-crashtrace=yes --disable-debug --enable-mmap=yes ZM_SSL_LIB=openssl; fi + - if [ "$ZM_BUILDMETHOD" = "cmake" ]; then cmake -DCMAKE_INSTALL_PREFIX="/usr"; fi - make - sudo make install after_success: - if [ "$ZM_BUILDMETHOD" = "cmake" ]; then sudo ./zmlinkcontent.sh; fi - - mysql -e "SET PASSWORD FOR travis = PASSWORD('zmpass')" - - mysql -utravis -pzmpass < db/zm_create.sql - - mysql -utravis -pzmpass zm < db/test.monitor.sql + - mysql -e "CREATE DATABASE IF NOT EXISTS zm" + - mysql -e "GRANT ALL ON zm.* TO 'zmuser'@'localhost' IDENTIFIED BY 'zmpass'"; + - mysql -uzmuser -pzmpass < db/zm_create.sql + - mysql -uzmuser -pzmpass zm < db/test.monitor.sql - sudo zmpkg.pl start