Travis support for PRs and master, stable5 and stable6

Continuation of #8913
One shell script per DBMS to do DBMS-specific things. Another shell script for performing other preparation.