toniblyx / alfresco-backup-and-recovery-tool

Alfresco BART is a tool written in shell script on top of Duplicity to do Alfresco backups and restore from a local file system, FTP, SCP or Amazon S3.
Apache License 2.0
96 stars 48 forks source link

Not an issue, but help. #41

Closed monicakumari closed 5 years ago

monicakumari commented 5 years ago

Hello,

I am trying to use this tool for backuping data to gcloud.

I have added some lines in alfresco-bart.sh :

case $BACKUPTYPE in "s3" ) export AWS_ACCESS_KEY_ID="${AWS_ACCESS_KEY_ID}" export AWS_SECRET_ACCESS_KEY="${AWS_SECRET_ACCESS_KEY}" DEST=${S3FILESYSLOCATION} PARAMS="${GLOBAL_DUPLICITY_PARMS} ${S3OPTIONS} ${NOENCFLAG}" ;; "gcloud" ) export GS_ACCESS_KEY_ID="${GS_ACCESS_KEY_ID}" export GS_SECRET_ACCESS_KEY="${GS_SECRET_ACCESS_KEY}" DEST=${GCLOUD_FILE_SYS_LOCATION} PARAMS="${GLOBAL_DUPLICITY_PARMS} ${NOENCFLAG}" ;; "ftp" ) if [ ${FTPS_ENABLE} == 'false' ]; then DEST=ftp://${FTP_USER}:${FTP_PASSWORD}@${FTP_SERVER}:${FTP_PORT}/${FTP_FOLDER} PARAMS="${GLOBAL_DUPLICITY_PARMS} ${NOENCFLAG}" else DEST=ftps://${FTP_USER}:${FTP_PASSWORD}@${FTP_SERVER}:${FTP_PORT}/${FTP_FOLDER} PARAMS="${GLOBAL_DUPLICITY_PARMS} ${NOENCFLAG}" fi ;; "scp" ) DEST=scp://${SCP_USER}@${SCP_SERVER}/${SCP_FOLDER} PARAMS="${GLOBAL_DUPLICITY_PARMS} ${NOENCFLAG}" ;;

I think, I need more configuration or something. I need help with backup to gcloud bucket.

Thanks.

douglascrp commented 5 years ago

Hello.

Is gcloud the Google Cloud Storage? As this option is not listed as supported by this project, you have 2 options: implement it by yourself, or raise an issue asking for a new feature, but in this case, you will have to wait until someone decides to go ahead and implement it.

Judging by the piece of code you shared, it seems you are in the right path, but for sure, that is not enough. We have just merged some major changes into the code, so I would like to suggest to you to grab the brand new code before trying to implement it. And if you want to have an idea about how to finish the feature you need, take a look at how I created the new SFTP option in this last PR that has just got merged. It will give you some ideas. And remember that you will have to install new dependencies in order to have duplicity talking with Google Storage/gcloud.

I have made a quick research, and found this https://medium.com/google-cloud/how-to-make-ubuntu-backups-using-duplicity-and-google-cloud-storage-849edcc4196e

I hope you find this answer useful.

monicakumari commented 5 years ago

Yes. thank you for your help. I have not tried it on latest update but somehow it worked.

Thanks, Hopefully we'll get this in easier way.