Class: Ansible::Ruby::Modules::Archive

Inherits:
Base show all
Defined in:
lib/ansible/ruby/modules/generated/files/archive.rb

Overview

Packs an archive. It is the opposite of M(unarchive). By default, it assumes the compression source exists on the target. It will not copy the source file from the local system to the target before archiving. Source files can be deleted after archival by specifying I(remove=True).

Instance Method Summary collapse

Methods inherited from Base

#ansible_name, #to_h

Methods inherited from Ansible::Ruby::Models::Base

attr_option, attr_options, attribute, #initialize, remove_existing_validations, #to_h, validates

Constructor Details

This class inherits a constructor from Ansible::Ruby::Models::Base

Instance Method Details

#destString?

Returns The file name of the destination archive. This is required when C(path) refers to multiple files by either specifying a glob, a directory or multiple paths in a list.

Returns:

  • (String, nil)

    The file name of the destination archive. This is required when C(path) refers to multiple files by either specifying a glob, a directory or multiple paths in a list.



20
# File 'lib/ansible/ruby/modules/generated/files/archive.rb', line 20

attribute :dest

#exclude_pathArray<String>, ...

Returns Remote absolute path, glob, or list of paths or globs for the file or files to exclude from the archive.

Returns:

  • (Array<String>, String, nil)

    Remote absolute path, glob, or list of paths or globs for the file or files to exclude from the archive



24
# File 'lib/ansible/ruby/modules/generated/files/archive.rb', line 24

attribute :exclude_path

#format:bz2, ...

Returns The type of compression to use.,Support for xz was added in version 2.5.

Returns:

  • (:bz2, :gz, :tar, :xz, :zip, nil)

    The type of compression to use.,Support for xz was added in version 2.5.



16
# File 'lib/ansible/ruby/modules/generated/files/archive.rb', line 16

attribute :format

#pathArray<String>, String

Returns Remote absolute path, glob, or list of paths or globs for the file or files to compress or archive.

Returns:

  • (Array<String>, String)

    Remote absolute path, glob, or list of paths or globs for the file or files to compress or archive.



12
# File 'lib/ansible/ruby/modules/generated/files/archive.rb', line 12

attribute :path

#remove:yes, ...

Returns Remove any added source files and trees after adding to archive.

Returns:

  • (:yes, :no, nil)

    Remove any added source files and trees after adding to archive.



28
# File 'lib/ansible/ruby/modules/generated/files/archive.rb', line 28

attribute :remove