From fac78c2f123c2aa993b8290d5273daacbd07c0da Mon Sep 17 00:00:00 2001 From: "Timothy M. Preble" Date: Sun, 22 Jul 2018 12:15:40 -0400 Subject: [PATCH] Update readme file --- README.md | 49 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 49 insertions(+) diff --git a/README.md b/README.md index 9b150ec..ba70fec 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,52 @@ #tsAPI3 -- Twitter API This project uses a local database to run stats on specified hash-tags. + +#Notes +https://medium.com/@rdsubhas/docker-for-development-common-problems-and-solutions-95b25cae41eb +#SCP +http://www.hypexr.org/linux_scp_help.php +https://www.howtoforge.com/tutorial/ssh-and-scp-with-public-key-authentication/ + + + + +#Package & Ship app to Pi + +#Move to parent (Code) Directory +cd /users/timpreble/Documents/code + +#Zip Main Folder + Files only. +https://www.gnu.org/software/tar/manual/tar.html#SEC35 + +tar +-c : create +-z : read or write archives through gzip, allowing tar to directly operate on several kinds of compressed archives transparently +-f : new file name +-v : verbose + +tar -czf folder_name.tar.gz folder_name/ +tar -czf tsAPI3.tar.gz tsAPI3/ + + + +#Ship Zip File to TSAPI3 +scp scp tsAPI3.tar.gz timp@RPi3(IPADDRESS):/docker-data + +#ssh to RPi3 +ssh RPi3 + +#move into correct directory & uncompress archive +cd /docker-data +tar -zxvf tsAPI3.tar.gz + +#Remove original archive +rm tar tsAPI3.tar.gz + +#Move into api dir & build docker image +cd /docker-data/tsAPI3 +docker build -t timpreble/tsapi:3.0 . + +#Run the container +docker run -d --name tsapi3 --restart=always -p 3001:3001 timpreble/tsapi:3.1 +