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

New 036_valid_output_methods.sh to error out for unsupported OUTPUT methods #2503

Merged
merged 1 commit into from Oct 19, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
13 changes: 13 additions & 0 deletions usr/share/rear/prep/default/036_valid_output_methods.sh
@@ -0,0 +1,13 @@

# For "rear mkbackup/mkrescue/mkbackuponly/mkopalpba"
# (i.e. for all workflows that run the 'prep' stage)
# check that the OUTPUT method is actually implemented
# i.e. check that a usr/share/rear/output/$OUTPUT directory exists
# and error out when an OUTPUT method seems to be not supported
# to ensure that the user cannot specify a non-working OUTPUT in /etc/rear/local.conf
# see https://github.com/rear/rear/issues/2501
# and cf. usr/share/rear/prep/default/035_valid_backup_methods.sh

if ! test -d "$SHARE_DIR/output/$OUTPUT" ; then
Error "The OUTPUT method '$OUTPUT' is not supported (no $SHARE_DIR/output/$OUTPUT directory)"
fi