GitLab – Configure GitLab Clients

Last updated on March 27th, 2018 at 09:13 am

## Use Git on Centos :

yum -t install git

## Create SSH Keys on Centos:

ssh-keygen -t rsa -C “[email protected]” -b 4096

## Copy SSH Keys to Git Server Keys:

cat ~/.ssh/id_rsa.pub

http://git01.yourdomain.com/profile/keys

# Go to Folder to Use Git as Repository:
cd /var/www/example.com

## Type the following lines on the Centos Client
(This command line instruction appear in Git Project):

git config –global user.name “Mister Admin”
git config –global user.email “[email protected]

git init
git remote add origin [email protected]:root/Web02.git
git add .
git commit -m “Initial commit”
git push -u origin master

### !! Clone Git Repository (Copy of Files & Folders) to Windows / Centos !! ###

git clone [email protected]:root/Web02.git

————–Client side———-

———–Install git Client on Centos ————
yum -y install git

———–Install git Client on Windows ————
64Bit— https://github.com/git-for-windows/git/releases/download/v2.15.1.windows.2/Git-2.15.1.2-64-bit.exe
32Bit— https://github.com/git-for-windows/git/releases/download/v2.15.1.windows.2/Git-2.15.1.2-32-bit.exe

———-Step 1 Create SSH Keys on bash Linux or bash on Windows————–

ssh-keygen -t rsa -C “[email protected]” -b 4096
cat ~/.ssh/id_rsa.pub

ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCmn0m+b8nvGJO3i3rNwMOtWClCJ0LIelllJPPE7LgSR1wRIrvYQgJ4b7r5wXPPSggiMB8wD8fqtKg+Lztb5XpVrBiK0DBTeY248Ms5DcQgabDziujEGEtwxGf157/+DYUSOBbf1f2zp7MVh+atr/Bsd1A66EPgaRwWyM7+4xptfkdzMbPd6z6Uro94pSIeBg1xv2Ep8WeKrdYGrdep2e4WePDWy11IgUPLKSHLXQXFpuN528Qwrj9276zvG5B/Sb+BJZFhzHDr/ptCINhlKypF8SG60rHuicTukNTxeJdL+956i2jcZMkRlQQaGpDaNBS6YyLlLq7NmriHVY7Y/Umzo/pu024vk4oWf26huGu5np8xsfbOF/cOCt3livzItMj6VefMN+jRQ3K2DGqPgAYwA7T90bYPsYCEEZHWeZ3zXcQiMmEj5pslyExI30TZBXEbiCx1pHJq+q4vCHshVAPQRYe8oaqY+IrFprdiElnWUrlRfzUbT2ErHbAyT1HJNrd5kNomACElc6cBM2QYNulsXgZriUuaLXIGIvXxznF6jsO6xm/Kj8P3VVPhcsgHzXTeqfjU1Yq4Hgba7bZsE+IjDSdO/JTPRxJrKKQ5vXTYMpxmu3u+CErWXgfv== [email protected]

————–Copy this Key to Git Keys ———–
http://git.yourdomain.local/profile/keys

————–Download Git Progect to local Windows PC————–

run git-bash

git clone [email protected]:admin/website.git