freezer.engine.tar.tar_builders
Module¶Licensed under the Apache License, Version 2.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an “AS IS” BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Freezer Tar related functions
freezer.engine.tar.tar_builders.
TarCommandBuilder
(filepath, compression_algo, is_windows, tar_path=None)¶Bases: object
Building a tar cmd command. To build command invoke method build.
DEREFERENCE_MODE
= {'all': '--hard-dereference --dereference', 'hard': '--hard-dereference', 'soft': '--dereference'}¶LISTED_TEMPLATE
= '{tar_command} --listed-incremental={listed_incremental}'¶UNIX_TEMPLATE
= '{gnutar_path} --create {algo} --warning=none --no-check-device --one-file-system --preserve-permissions --same-owner --seek --ignore-failed-read'¶WINDOWS_TEMPLATE
= '{gnutar_path} -c {algo} --incremental --unlink-first --ignore-zeros'¶build
()¶set_dereference
(mode)¶set_encryption
(encrypt_pass_file, openssl_path=None)¶set_exclude
(exclude)¶set_listed_incremental
(absolute_path)¶freezer.engine.tar.tar_builders.
TarCommandRestoreBuilder
(restore_path, compression_algo, is_windows, tar_path=None)¶Bases: object
DRY_RUN_TEMPLATE
= '{0} {1} --incremental --list --ignore-zeros --warning=none'¶OPENSSL_DEC
= '{openssl_path} enc -d -aes-256-cfb -pass file:{file}'¶UNIX_TEMPLATE
= '{0} {1} --incremental --extract --ignore-zeros --warning=none --overwrite --directory {2}'¶WINDOWS_TEMPLATE
= '{0} -x {1} --incremental --unlink-first --ignore-zeros'¶build
()¶set_dry_run
()¶set_encryption
(encrypt_pass_file, openssl_path=None)¶freezer.engine.tar.tar_builders.
get_tar_flag_from_algo
(compression)¶Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.