This addresses the corner case where encrypt.key is provided so a
TextEncryptor is available in the bootstrap context. Previously
it was not used and the /encrypt endpoints wouldn't work.
Fixes gh-760
By default, Spring Cloud Config Server uses SSH configuration files such
as ~/.ssh/known_hosts and /etc/ssh/ssh_config when connecting to Git repositories
using an SSH URI. In cloud environments such as Cloud Foundry,
the local filesystem may be ephemeral or not easily accessible.
For cases such as these, SSH configuration can be set using Java properties.
In order to activate property based SSH configuration,
the property spring.cloud.config.server.git.ignoreLocalSshSettings must be set to true
A stale lock from a crashed JVM can prang the JGit client by
preventing it from ever getting access to the working directory.
This change attempts to clean the slate by removing the lock -
because of the synchronization already present in the repository
the only way this can go wrong is if multiple server instances
are trying to share the working directory (which would be an
eror for other reasons).
Before this change when a repository is created to support a pattern match
in the URL, the basedir for cloning the scm repository is a new temp dir.
So if user configures the basedir to be something other than temp then he
loses the benefit once patterns are used in the URL matchers.
The basedir still has to be unique, so we now use the same parent directory
as the parent repo, and add the temp file name as a directory name. I.e.
if basedir=/foo/bar the pattern matched basedir will be something like
/foo/config-repo-23874691. You need the directory to have a parent that
is writable by the config server JVM.
Fixes gh-451
When findOne() is called with an application parameter that matches the defaultKey property value then
the returned Environment contains two identical PropertySource values when it should only contain one.