Merge branch 'CDB-3079' of https://github.com/CartoDB/CartoDB-SQL-API into CDB-2038
This commit is contained in:
commit
9133893e39
26
.travis.yml
26
.travis.yml
@ -1,13 +1,19 @@
|
|||||||
before_install:
|
before_script:
|
||||||
#- sudo apt-add-repository --yes ppa:ubuntugis/ppa
|
- lsb_release -a
|
||||||
- sudo apt-get update -q
|
- sudo mv /etc/apt/sources.list.d/pgdg-source.list* /tmp
|
||||||
# Removal of postgresql-9.1-postgis-scripts is needed due to a
|
- sudo apt-get -qq purge postgis* postgresql*
|
||||||
# bug in some upstream package.
|
- sudo rm -Rf /var/lib/postgresql /etc/postgresql
|
||||||
# See http://trac.osgeo.org/ubuntugis/ticket/39
|
- sudo apt-add-repository --yes ppa:cartodb/postgresql-9.3
|
||||||
- sudo apt-get remove --purge -q postgresql-9.1-postgis-scripts
|
- sudo apt-add-repository --yes ppa:cartodb/gis
|
||||||
- sudo apt-get install -q postgresql-9.1-postgis gdal-bin
|
- sudo apt-get update
|
||||||
- createdb template_postgis
|
- sudo apt-get install -q postgresql-9.3-postgis-2.1
|
||||||
- psql -c "CREATE EXTENSION postgis" template_postgis
|
- sudo apt-get install -q postgresql-contrib-9.3
|
||||||
|
- sudo apt-get install -q postgis
|
||||||
|
- sudo apt-get install -q gdal-bin
|
||||||
|
- echo -e "local\tall\tall\ttrust\nhost\tall\tall\t127.0.0.1/32\ttrust\nhost\tall\tall\t::1/128\ttrust" |sudo tee /etc/postgresql/9.3/main/pg_hba.conf
|
||||||
|
- sudo service postgresql restart
|
||||||
|
- psql -c 'create database template_postgis;' -U postgres
|
||||||
|
- psql -c 'CREATE EXTENSION postgis;' -U postgres -d template_postgis
|
||||||
- ./configure
|
- ./configure
|
||||||
|
|
||||||
language: node_js
|
language: node_js
|
||||||
|
@ -65,18 +65,18 @@ export PGHOST PGPORT
|
|||||||
if test x"$PREPARE_PGSQL" = xyes; then
|
if test x"$PREPARE_PGSQL" = xyes; then
|
||||||
|
|
||||||
echo "preparing postgres..."
|
echo "preparing postgres..."
|
||||||
dropdb ${TEST_DB} # 2> /dev/null # error expected if doesn't exist, but not otherwise
|
dropdb -U postgres ${TEST_DB} # 2> /dev/null # error expected if doesn't exist, but not otherwise
|
||||||
createdb -Ttemplate_postgis -EUTF8 ${TEST_DB} || die "Could not create test database"
|
createdb -U postgres -Ttemplate_postgis -EUTF8 ${TEST_DB} || die "Could not create test database"
|
||||||
cat test.sql |
|
cat test.sql |
|
||||||
sed "s/:PUBLICUSER/${PUBLICUSER}/" |
|
sed "s/:PUBLICUSER/${PUBLICUSER}/" |
|
||||||
sed "s/:PUBLICPASS/${PUBLICPASS}/" |
|
sed "s/:PUBLICPASS/${PUBLICPASS}/" |
|
||||||
sed "s/:TESTUSER/${TESTUSER}/" |
|
sed "s/:TESTUSER/${TESTUSER}/" |
|
||||||
sed "s/:TESTPASS/${TESTPASS}/" |
|
sed "s/:TESTPASS/${TESTPASS}/" |
|
||||||
psql -v ON_ERROR_STOP=1 ${TEST_DB} || exit 1
|
psql -U postgres -v ON_ERROR_STOP=1 ${TEST_DB} || exit 1
|
||||||
|
|
||||||
# TODO: send in a single run, togheter with test.sql
|
# TODO: send in a single run, togheter with test.sql
|
||||||
psql -f support/CDB_QueryStatements.sql ${TEST_DB}
|
psql -U postgres -f support/CDB_QueryStatements.sql ${TEST_DB}
|
||||||
psql -f support/CDB_QueryTables.sql ${TEST_DB}
|
psql -U postgres -f support/CDB_QueryTables.sql ${TEST_DB}
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user