Fixing forgotten $CDIR in configure

```
CDIR=/etc/config-tools
-generate 0 /etc/config-tools/config
+generate 0 $CDIR/config
. $CDIR/config
```
Merge pull request #13 from gaelL/master

Fix forgotten $CDIR in configure
Use $JENKINS_HOME to reach id_rsa SSH key

If present, use $JENKINS_HOME to reach the id_rsa SSH key and properly
connect to remote hosts by SSH with SSHOPTS options.
fixup : pass environment variables WORKSPACE JOB_NAME BUILD_ID JENKINS_HOME thru sudo
configure: restart apache after disabling puppetmaster

Before: Apache was configured, puppetdb started and Apache started.
It led to some issues during the upgrade where Apache did not restart
because it was already started and needed to be restarted for some
configurations changes reasons.

Now: Apache is configured, puppetdb started and Apache restarted to
ensure Puppet will run correctly.
configure: restart puppetdb instead of just start it

In some cases, PuppetDB could be start for whatever reasons. During the
0th step, let's ensure we restart the service.
configure: chown puppet:puppet /etc/puppet

All puppet files should be owned by Puppet user and not root.
configure.sh: Add umask in envvars due to wrong file permission
configure: chmod 0644 hiera files

Ensure we have right permissions on Hiera files on the install-server.
Otherwise, it could lead to permissions errors, and the puppet catalog
could fail to compile.
Revert "configure: chown puppet:puppet /etc/puppet"

This reverts commit ab80e96d280a33b3fed4441bf9eb59209df5f4a8.
download: Handle the new scenario section in the deployment file

User can now specify a scenario section in their deployment file.
This commit will base the infra.yaml on the scenario specified,
or default to root infra.yaml file if nothing is specified.
Merge pull request #15 from enovance/new_deployment_file

download: Handle the new scenario section in the deployment file
download: move infra.yml -> infra.yaml
extract-archive/jjb: allow job dupplication to support upgrade

This patch aims to support the upgrade from I.1.1.0 to I.1.2.0 in
Jenkins Job Builder. Because we are updating the jobs and have
dupplicate, we should allow job dupplication. This is a new feature in
JJB: http://goo.gl/1dDhye
Add functions file

Add functions file, load it in extract-archive and use an useful
function to configure parameters.
send: also rsync "functions" file
Permissions : Set proper permission for hiera.yaml, puppetdb.conf and routes.yaml

Those files needs to be readable by the user running puppet, else it would prevent
it to run, and a ugly passenger error will be displayed.
configure: apply chown on real puppetdb config file

Last commit introduced an error, we don't have /etc/puppet/puppetdb.yaml
but /etc/puppet/puppetdb.conf.
configure: chown puppet:puppet /etc/puppet/autosign.conf
configure: set right permissions to Hiera files