-
-
Notifications
You must be signed in to change notification settings - Fork 136
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add sshPublicKeysDirectoryPath and GIT_CONFIG_EXTENSIONS parameters t…
…hat adds git configs and mounts .ssh/config and public keys to the container, in order to allow multiple sh deploy key trick by webplatform@ssh-agent (#240)
- Loading branch information
Showing
8 changed files
with
1,258 additions
and
1,174 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
#!/usr/bin/env bash | ||
|
||
if [ -z "${GIT_CONFIG_EXTENSIONS}" ] | ||
then | ||
echo "GIT_CONFIG_EXTENSIONS unset skipping" | ||
else | ||
echo "GIT_CONFIG_EXTENSIONS is set. configuring extra git configs" | ||
|
||
IFS=$'\n' | ||
for config in $(echo "${GIT_CONFIG_EXTENSIONS}" | sed 's/\(.*\)=\(.*\)/"\1" "\2"/g'); do | ||
if [[ $config =~ \"([^\"]+)\"\ \"([^\"]+)\" ]]; then | ||
key="${BASH_REMATCH[1]}" | ||
value="${BASH_REMATCH[2]}" | ||
else | ||
echo "Error parsing config: $config" | ||
exit 1 | ||
fi | ||
echo "Adding extra git config: \"$key\" = \"$value\"" | ||
git config --global --add "$key" "$value" | ||
done | ||
unset IFS | ||
|
||
fi | ||
|
||
echo "---------- git config --list -------------" | ||
git config --list | ||
|
||
echo "---------- git config --list --show-origin -------------" | ||
git config --list --show-origin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters