mirror of
https://github.com/vincentmli/bpfire.git
synced 2026-04-26 02:42:58 +02:00
Merge remote-tracking branch 'origin/master' into next
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
###############################################################################
|
||||
# #
|
||||
# IPFire.org - A linux based firewall #
|
||||
# Copyright (C) 2007-2012 IPFire Team <info@ipfire.org> #
|
||||
# Copyright (C) 2007-2021 IPFire Team <info@ipfire.org> #
|
||||
# #
|
||||
# This program is free software: you can redistribute it and/or modify #
|
||||
# it under the terms of the GNU General Public License as published by #
|
||||
@@ -22,17 +22,28 @@
|
||||
. /etc/sysconfig/rc
|
||||
. $rc_functions
|
||||
|
||||
TAR_OPTIONS=(
|
||||
--acls
|
||||
--xattrs
|
||||
--xattrs-include='*'
|
||||
--no-overwrite-dir
|
||||
--no-delay-directory-restore
|
||||
--preserve-permissions
|
||||
--numeric-owner
|
||||
)
|
||||
|
||||
extract_files() {
|
||||
echo "Extracting files..."
|
||||
tar --acls --xattrs --xattrs-include='*' \
|
||||
-xavf /opt/pakfire/tmp/files* --no-overwrite-dir -p --numeric-owner -C /
|
||||
tar -xavf /opt/pakfire/tmp/files* "${TAR_OPTIONS[@]}" -C /
|
||||
sync
|
||||
echo "...Finished."
|
||||
}
|
||||
|
||||
extract_backup_includes() {
|
||||
echo "Extracting backup includes..."
|
||||
tar xavf /opt/pakfire/tmp/files* --no-overwrite-dir -p --numeric-owner -C / \
|
||||
tar xavf /opt/pakfire/tmp/files* "${TAR_OPTIONS[@]}" -C / \
|
||||
var/ipfire/backup/addons/includes
|
||||
sync
|
||||
echo "...Finished."
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user