DevOps Tools and Documentation. If your desktop using windows, download and install git-scm. Use terminal or git bash for the next section.


Please make sure your server or desktop has SSH key. To check it please do this command :

cat ~/.ssh/

if there is no key appears, plese generate the key also set global config of git and please add the public key to your github profile.

ssh-keygen -t rsa -b 4096 -C ""
git config --global ""
git config --global "Rolly Maulana Awangga"
cat ~/.ssh/

Detail Tutorial using git

Using Google Colab with Drive and Git Repository

Mounting drive and generate ssh

import os
from google.colab import drive
folder = '/content/drive/My Drive/SK2/fix/siabre' 

os.chdir(savedir)  #change dir

generate ssh key, add host, and backup key to current folder for next future use

!ssh-keygen -t rsa -b 4096 -C ""
!git config --global "Rolly Maulana Awangga"
!git config --global
!ssh-keyscan -t rsa >> ~/.ssh/known_hosts
!cat ~/.ssh/
!cp -R /root/.ssh/ ./ssh/

for next use just

!cp -R ./ssh/ /root/.ssh/

clone and change dir

!git clone url
os.chdir('/content/drive/My Drive/SK2/fix/siabre')

Connect Source Code to Git

Please create git repo first and copy ssh uri, for example :

use it in replace with : git remote add origin Go to your website folder for example in : /var/www/html/siap

cd /var/www/html/siap
git init
git commit -m "first commit"
git remote add origin
git pull origin main --allow-unrelated-histories
git push origin main

MariaDB Database migration

If database name is dbname then, On Source Server :

mysqldump -u root -p --opt dbname > dbname.sql
scp dbname.sql user@

then go to target server:

ssh user@
mysql -u root -p dbname < dbname.sql

SSH Without Password

Using git bash create yout key, you dont have to do this if you already have a key

ssh-keygen -t rsa -b 4096 -C ""

send key to the server

cat ~/.ssh/ | ssh 'cat >> .ssh/authorized_keys'

ssh into server and change permission

chmod 700 .ssh; chmod 640 .ssh/authorized_keys

Check Disk Usage

sudo du -hc --max-depth=1 /