Cloudron Backups to GitLab/GitHub Private Repos
-
I'm happy with the current paid backup options with their service levels that come with it - but it occurred to me that GitLab.com & GitHub.com both effectively offer unlimited storage for free, and Git Large File Support (LFS) now too.
Inspired a little by this neat app that turns a Git Repo into a Dropbox/GDrive type service:
And since encrypted backups are an option, there's additional security.
Not a high priority - but might be nice for both the really tight and multi-location/provider redundancy aims.
Plus it's already a version-control system for historic records, so could help cover some of the legal compliance archiving of records needs for companies.
Just a thought but maybe something in this?
-
I'm happy with the current paid backup options with their service levels that come with it - but it occurred to me that GitLab.com & GitHub.com both effectively offer unlimited storage for free, and Git Large File Support (LFS) now too.
Inspired a little by this neat app that turns a Git Repo into a Dropbox/GDrive type service:
And since encrypted backups are an option, there's additional security.
Not a high priority - but might be nice for both the really tight and multi-location/provider redundancy aims.
Plus it's already a version-control system for historic records, so could help cover some of the legal compliance archiving of records needs for companies.
Just a thought but maybe something in this?
@marcusquinn
I think if you choose "SSHFS Mount" in the options and throw in your gitlab repo credentials / path that it would probably work??? I am not 100% sure tho.Sike - Try this instead:
- Enable
Filesystemas the backupStorage Provider - Pick a path on your Cloudron HDD, something like
/home/backups/gitlab - Initialize it as a git repo:
cd /home/backups/gitlab && git init && git remote add origin https://gitlab-server/username/repository - Make sure to save the password in git as well:
git config --global credential.helper storethen pull the empty repo to store password. NOTE: you should use a randomly generated username and password as they will be stored in PLAINTEXT here. - Put the following in crontab
00 23 * * * /home/backups/gitlab_script.sh
Essentially this cron job runs everyday at 11PM server time. - Put the following in
/home/backups/gitlab_script.sh:
#!/bin/bash ## Todays date NOW=$(date +"%m-%d-%Y") ## Change DIR to backups path cd /home/backups/gitlab ## Add changed files git add -A ## Add untracked (not tracked) files to git git add -u ## Commit to git git commit -m "Backup $NOW" ## Push to gitlab git push origin masterthat should do it, but note, it will take a long time to process.
- Enable
-
@marcusquinn
I think if you choose "SSHFS Mount" in the options and throw in your gitlab repo credentials / path that it would probably work??? I am not 100% sure tho.Sike - Try this instead:
- Enable
Filesystemas the backupStorage Provider - Pick a path on your Cloudron HDD, something like
/home/backups/gitlab - Initialize it as a git repo:
cd /home/backups/gitlab && git init && git remote add origin https://gitlab-server/username/repository - Make sure to save the password in git as well:
git config --global credential.helper storethen pull the empty repo to store password. NOTE: you should use a randomly generated username and password as they will be stored in PLAINTEXT here. - Put the following in crontab
00 23 * * * /home/backups/gitlab_script.sh
Essentially this cron job runs everyday at 11PM server time. - Put the following in
/home/backups/gitlab_script.sh:
#!/bin/bash ## Todays date NOW=$(date +"%m-%d-%Y") ## Change DIR to backups path cd /home/backups/gitlab ## Add changed files git add -A ## Add untracked (not tracked) files to git git add -u ## Commit to git git commit -m "Backup $NOW" ## Push to gitlab git push origin masterthat should do it, but note, it will take a long time to process.
@murgero Interesting, will give it a try and feedback here if it works as then it would be devs favourite solution; just be some notes added to the docs.


- Enable
-
@murgero Interesting, will give it a try and feedback here if it works as then it would be devs favourite solution; just be some notes added to the docs.


-
@marcusquinn Check my edit - much better solution.
@murgero Interesting - that covers it being multi-backups nicely too! Certainly one to try with caution for the CPU & Bandwidth though but good that it's a possibility.
-
@murgero Interesting - that covers it being multi-backups nicely too! Certainly one to try with caution for the CPU & Bandwidth though but good that it's a possibility.
-
I'm happy with the current paid backup options with their service levels that come with it - but it occurred to me that GitLab.com & GitHub.com both effectively offer unlimited storage for free, and Git Large File Support (LFS) now too.
Inspired a little by this neat app that turns a Git Repo into a Dropbox/GDrive type service:
And since encrypted backups are an option, there's additional security.
Not a high priority - but might be nice for both the really tight and multi-location/provider redundancy aims.
Plus it's already a version-control system for historic records, so could help cover some of the legal compliance archiving of records needs for companies.
Just a thought but maybe something in this?
@marcusquinn said in Cloudron Backups to GitLab/GitHub Private Repos:
Not a high priority - but might be nice for both the really tight and multi-location/provider redundancy aims.
I have to think through the rest but multi-location backups is in our radar. We have a long pending issue about this https://git.cloudron.io/cloudron/box/-/issues/528
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login