commit by to_remotes 2024-05-03 13:11:29 +0200 from vmdevhw
parent
9c63192b55
commit
a6886d4beb
|
|
@ -13,7 +13,7 @@ function init_repos(){
|
|||
echo -n "deploy key suffix. Leave blank if first: "
|
||||
read -r DEPLOY_KEY_SUFFIX
|
||||
|
||||
if [ ! -f $HOME/.ssh/deploy_key$DEPLOY_KEY_SUFFIX ]; then
|
||||
if [ ! -f $HOME/.ssh/deploy_key ]; then
|
||||
|
||||
echo "create ssh key"
|
||||
echo -n "ssh passphrase: "
|
||||
|
|
@ -28,7 +28,7 @@ function init_repos(){
|
|||
|
||||
mkdir -p $HOME/.ssh
|
||||
|
||||
ssh-keygen -t rsa -N "$passphrase" -C "deploy_key_$CLIENT_NAME" -f $HOME/.ssh/deploy_key$DEPLOY_KEY_SUFFIX
|
||||
ssh-keygen -t rsa -N "$passphrase" -C "deploy_key_$CLIENT_NAME$DEPLOY_KEY_SUFFIX" -f $HOME/.ssh/deploy_key
|
||||
|
||||
echo "please upload now pub key by logging into user $CLIENT_NAME keys ..."
|
||||
echo "if user does not exit. login with admin user and create new user with name: $CLIENT_NAME"
|
||||
|
|
@ -38,7 +38,7 @@ function init_repos(){
|
|||
echo "https://git.service.wiseadvice.eu/user/settings/keys"
|
||||
echo " "
|
||||
|
||||
cat $HOME/.ssh/deploy_key$DEPLOY_KEY_SUFFIX.pub
|
||||
cat $HOME/.ssh/deploy_key.pub
|
||||
fi
|
||||
|
||||
echo " "
|
||||
|
|
@ -58,7 +58,7 @@ function init_repos(){
|
|||
cat <<EOT >> $HOME/.ssh/config
|
||||
Host git.service.wiseadvice.eu
|
||||
HostName git.service.wiseadvice.eu
|
||||
IdentityFile ~/.ssh/deploy_key$DEPLOY_KEY_SUFFIX
|
||||
IdentityFile ~/.ssh/deploy_key
|
||||
Port 8422
|
||||
IdentitiesOnly yes
|
||||
EOT
|
||||
|
|
|
|||
Loading…
Reference in New Issue