Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keep multiple versions of backup #6

Open
MaartenUreel opened this issue Jan 25, 2020 · 2 comments
Open

Keep multiple versions of backup #6

MaartenUreel opened this issue Jan 25, 2020 · 2 comments

Comments

@MaartenUreel
Copy link

MaartenUreel commented Jan 25, 2020

If I understood correctly, you will always remove the other versions of the backups. However it might make sense to keep e.g. the last 14 versions, no?

Would you feel like making that into a parameter?

@padelt
Copy link
Owner

padelt commented Jan 25, 2020

I can’t do that myself as I don’t use B2 with Proxmox at the moment. I’d be happy to merge PR if you can prepare one, though!

@MaartenUreel
Copy link
Author

Unfortunately Bash scripting isn't my thing, I would have to do it in Python, but I think this could be implemented:
You are using list_file_names to retrieve the files from b2 and you extract files[]|.fileName+"'$DELIMITER'"+.fileId from that.

However you could check files[]|.fileName+"'$DELIMITER'"+.uploadTimestamp and ignore files that were uploaded in the last $UPLOAD_RETENTION days?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants