MT#8117 set defaults to localhost:3306 for central/pair

Get rid of the warning in installer because we don't have yet
the proper configs

Change-Id: I07bcc070b880c46472c49f06b3144f1ce9281f19
MT#7623 MT#8155 don't exit if network.yml doesn't exist

In the CARRIER install phase network.yml is not there yet

Change-Id: I37952ccf9392c3fd472a2a2b916acb654d198503
MT#8623 set the repuser password only if the replication is already set

From MYSQL documentation:
"If you specify the MASTER_HOST or MASTER_PORT option, the slave
assumes that the master server is different from before
(even if the option value is the same as its current value.)
In this case, the old values for the master binary log file
name and position are considered no longer applicable"

Change-Id: I9be8e0fdab7ce598343df270c2ade0a5095e1f48
MT#8127 set password for repuser on slaves in the grant command

The repuser on RO slaves couldn't connect do this.

Change-Id: Ic9e5e007c9f6291e20eec26d75ab75193cd407f8
MT#8117 Swtich defaults from 127.0.0.1 to localhost

We have a regression here for CE during the upgrade mr3.4->trunk:
> Removing proj-data ...
> ...
> Synchronizing data from /etc/ngcp-config/constants.yml
> DBI connect('database=mysql;host=127.0.0.1;port=3306','sipwise',...) failed:
> Can't connect to MySQL server on '127.0.0.1' (111) 
> at /usr/sbin/ngcp-sync-constants line 131
> Can't connect to MySQL database mysql: Can't connect to MySQL server on
> '127.0.0.1' (111) at /usr/sbin/ngcp-sync-constants line 131.

It happens because MySQL listens Unix sockets only (due to "skip_networking" in my.cnf)
It doesn't affect newly installed CE trunk, 
because it has defaults in /etc/ngcp-config/config.yml:
> database:
>   central:
>     dbhost: localhost
>   pair:
>     dbhost: localhost

While upgraded system not yet received those options 
(ngcp-upgrade-cfg-schema will be called later).
So, we need to change defaults here to localhost. 
MySQL always uses unix sockets for 'localhost'.

Change-Id: I0f07c43ea68ed47b653242cd87ed74e7351dcc1c
MT#8763 allow multiple config directories on templates not only "/etc"

Change-Id: I1c8fc5fd45a0c34ba7542ddc6ce24793bd568cb5
MT#8763 check for .git before running the services

On a multi directory config, the services depends on git. Check
first if the git repository exists and warn about it

Change-Id: I52e335c85ecf4a330da44b3088725623f3c04531
MT#8773 ngcp-sync-constants: grant user sipwise on pair when running with '-r' option

Change-Id: I4f147fcae147e9c37b8f51dc5a9e1d946b716601
MT#8763 Add backward compatibility for mr3.4->mr3.5 PRO upgrade

Otherwise we faced the error during upgrading the second node (sp2):
> Script started on Fri 29 Aug 2014 10:34:23 AM CEST
> Not prompting user for approval because environment variable FORCE_UPGRADE is present.
> /usr/share/ngcp-upgrade-trunk/upgrade-stable-to-trunk - start on Fri Aug 29 10:34:23 CEST 2014
> Looks like you are running Debian 7 already.
> Checking for (possibly) outstanding ngcpcfg changes
> /usr/share/ngcp-ngcpcfg/functions//main: line 78: TEMPLATE_POOL: unbound variable

The node sp1 has been upgraded succesfully but new config ngcpcfg.cfg has been
delievered to sp2 and old ngcpcfg framework failed to start with new config.

Those workaround can be reverted as soon as next LTS release is released.

Change-Id: Idb1f4ca05e88e7a30054ace0c0b47dc0eadf1b7a