Comments (11)
I have incorporated your pull request, but I cannot help but thinking we could do better. Shouldn't emborg automatically set prefix for the user? That would require splitting the archive setting in into two settings, perhaps archive_prefix and archive. Or perhaps archive can be converted into the prefix and I just always add {{now}} to the end of whatever is specified. What do you think?
from emborg.
If not specified, the archive setting is now derived from the prefix setting. If neither is specified then prefix defaults to '{config_name}-'.
from emborg.
-
prefix Yes it makes sense to go further with the prefix. Then, if I understand well, this could be a breaking change as names will be different without user's intervention in the settings. Just something to be careful about.
-
suffix As far as suffix are concerned, I personnally use
{{now:%Y%m%d}}
, if implemented it would be good to have the option and not necessarily have{{now}}
at the end.
from emborg.
from emborg.
Understood, and I agree let's keep it simple no need for more parameters for the now
format.
The prefix will be applied for pruning and not for listing if I understand well, I am fine with that or with another solution but this is just to make sure I get the current implementation.
from emborg.
I have now extended the use of prefix to all the commands that support it, specifically check, delete, info, list, mount, and prune. I spent some time refining my changes and the documentation, but I believe I am done for now. So I recommend that you pull the latest version (1.4.4) from github.
from emborg.
very good, then is it now still possible to list all the archives of the repo without the prefix?
Also, I would have thought that the default prefix would be the hostname: a config can be copied on several hosts and backup on the same repo using their hostname as a prefix without overlapping.
from emborg.
I can add a --all option that blocks the --prefix option, meaning that list would list all archives. Is this something that would be useful for all commands that use --prefix. Seems like it would be.
I can change the default prefix to hostname.
from emborg.
Yes I think -all would be useful for all commands with prefix, to be used with caution for pruning but this is user's responsibility, the ability to do it makes sense.
default prefix: to make sure I am not making a wrong interpretation, I have checked again the Borg quickstart and they use '{hostname}-' as an example. It makes sense to use it this way as a default.
Use the
prune
subcommand to maintain 7 daily, 4 weekly and 6 monthly
archives of THIS machine. The '{hostname}-' prefix is very important to
limit prune's operation to this machine's archives and not apply to
other machines' archives also:
borg prune
--list
--prefix '{hostname}-'
--show-rc
--keep-daily 7
--keep-weekly 4
--keep-monthly 6 \
from emborg.
Okay, I will add the --all option.
On the default prefix, Borg does not have the concept of a config, so I don't think we can use the Borg documentation too literally. I am beginning to think that the safest thing to do is to use the following as the default prefix: '{host_name}-{user_name}-{config_name}-'. That way there is almost no chance of a conflict.
from emborg.
Okay, I have updated emborg to version 1.4.5. I implemented the --all option as --include-external (I reserved --all for the mount command) and I changed the default prefix so that it includes the host name, the user name, and the config name.
from emborg.
Related Issues (20)
- Healthchecks 'success' not sent when borg returns 1 (which is only a warning) HOT 11
- Unable to run tests in 1.29 HOT 8
- Clearer explanation of "working_dir" and paths? HOT 2
- run_after_last_backup may sometimes run too soon HOT 5
- Support for 'borg compact' HOT 3
- "emborg --narrate create" with "check_after_create = 'latest'" prints entire output of "borg list" to stdout HOT 4
- Support for borg create --upload-ratelimit in borg 1.2 HOT 2
- compact_after_delete generates error HOT 6
- Occasional test failures HOT 1
- Add support for 'recreate' HOT 3
- Tests fail on v1.33 with borg 1.2.2 HOT 4
- Tests not runnable on case-insensitive systems HOT 3
- Composite create fails HOT 2
- Tests fail on v1.36 HOT 4
- nestedtext new dependency HOT 2
- Dry run option doesn't work for `emborg check --repair` HOT 2
- Somewhere along the line emborg stopped posting to healthchecks.io HOT 3
- Recommended install with new pip limitations HOT 5
- Default config uses notify-send which is not mentioned in dependencies or installation instructions HOT 3
- Last backup stats not recorded correctly. HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from emborg.