mosh
basic things
mosh opc@oracle-learn # 1) learn.ilima.xyz
mosh opc@oracle-docker # 2) docker.ilima.xyz
# upload: local -> remote
scp ~/Downloads/file.txt opc@oracle-learn:/home/opc/file.txt
# download: remote -> local
scp opc@oracle-learn:/home/opc/file.txt ~/Downloads/
when an IDE instance die/stop/shutdown
# start Docker
sudo systemctl start docker
# stop Docker
sudo systemctl stop docker
sudo systemctl stop docker.socket
# give it a go
sudo docker run hello-world
Synchronize a local directory with a remote machine utilizing Secure Shell (SSH) protocol.
# synchronize folder to a remote machine using ssh
# sync the remote destionation to a local destination
rsync -urltv -e ssh opc@oracle-learn:/home/opc/tmp-20240309-2236/ `realpath ~/Downloads/tmp`
# from local destination to a remote destination
rsync -urltv -e ssh `realpath ~/Downloads/tmp` opc@oracle-learn:/home/opc/tmp-20240309-2236/
Note: the rsync options used here are:
-u,--updateskip files that are newer on the receiver-r,--recursiverecurse into directories-l,--linkscopy symlinks as symlinks-t,--timespreserve modification times-v,--verboseincrease verbosity--deletedelete extraneous files from dest dirs, acts as--delete-during-aoption means “archive mode” which can be used to sync directories, transfer files, and preserve ownership and permissions.- lastly,
-eis the option that allows you to specify your remote shell, in this case ssh