Class: Ansible::Ruby::Modules::Unarchive

Inherits:
Base show all
Includes:
Helpers::FileAttributes
Defined in:
lib/ansible/ruby/modules/generated/files/unarchive.rb,
lib/ansible/ruby/modules/custom/files/unarchive.rb

Overview

The C(unarchive) module unpacks an archive. By default, it will copy the source file from the local system to the target before unpacking. Set C(remote_src=yes) to unpack an archive which already exists on the target. For Windows targets, use the M(win_unzip) module instead. If checksum validation is desired, use M(get_url) or M(uri) instead to fetch the file and set C(remote_src=yes).

Instance Method Summary collapse

Methods included from Helpers::FileAttributes

included

Methods inherited from Base

#ansible_name, #to_h

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

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

Constructor Details

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

Instance Method Details

#copy:yes, ...

Returns If true, the file is copied from local ‘master’ to the target machine, otherwise, the plugin will look for src archive at the target machine.,This option has been deprecated in favor of C(remote_src).,This option is mutually exclusive with C(remote_src).

Returns:

  • (:yes, :no, nil)

    If true, the file is copied from local ‘master’ to the target machine, otherwise, the plugin will look for src archive at the target machine.,This option has been deprecated in favor of C(remote_src).,This option is mutually exclusive with C(remote_src).



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

attribute :copy

#createsObject?

Returns If the specified absolute path (file or directory) already exists, this step will B(not) be run.

Returns:

  • (Object, nil)

    If the specified absolute path (file or directory) already exists, this step will B(not) be run.



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

attribute :creates

#destString

Returns Remote absolute path where the archive should be unpacked.

Returns:

  • (String)

    Remote absolute path where the archive should be unpacked.



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

attribute :dest

#excludeObject?

Returns List the directory and file entries that you would like to exclude from the unarchive action.

Returns:

  • (Object, nil)

    List the directory and file entries that you would like to exclude from the unarchive action.



35
# File 'lib/ansible/ruby/modules/generated/files/unarchive.rb', line 35

attribute :exclude

#extra_optsString?

Returns Specify additional options by passing in an array.

Returns:

  • (String, nil)

    Specify additional options by passing in an array.



42
# File 'lib/ansible/ruby/modules/generated/files/unarchive.rb', line 42

attribute :extra_opts

#keep_newer:yes, ...

Returns Do not replace existing files that are newer than files from the archive.

Returns:

  • (:yes, :no, nil)

    Do not replace existing files that are newer than files from the archive.



38
# File 'lib/ansible/ruby/modules/generated/files/unarchive.rb', line 38

attribute :keep_newer

#list_files:yes, ...

Returns If set to True, return the list of files that are contained in the tarball.

Returns:

  • (:yes, :no, nil)

    If set to True, return the list of files that are contained in the tarball.



31
# File 'lib/ansible/ruby/modules/generated/files/unarchive.rb', line 31

attribute :list_files

#remote_src:yes, ...

Returns Set to C(yes) to indicate the archived file is already on the remote system and not local to the Ansible controller.,This option is mutually exclusive with C(copy).

Returns:

  • (:yes, :no, nil)

    Set to C(yes) to indicate the archived file is already on the remote system and not local to the Ansible controller.,This option is mutually exclusive with C(copy).



46
# File 'lib/ansible/ruby/modules/generated/files/unarchive.rb', line 46

attribute :remote_src

#srcString

Returns If C(remote_src=no) (default), local path to archive file to copy to the target server; can be absolute or relative. If C(remote_src=yes), path on the target server to existing archive file to unpack.,If C(remote_src=yes) and C(src) contains C(://), the remote machine will download the file from the URL first. (version_added 2.0). This is only for simple cases, for full download support use the M(get_url) module.

Returns:

  • (String)

    If C(remote_src=no) (default), local path to archive file to copy to the target server; can be absolute or relative. If C(remote_src=yes), path on the target server to existing archive file to unpack.,If C(remote_src=yes) and C(src) contains C(://), the remote machine will download the file from the URL first. (version_added 2.0). This is only for simple cases, for full download support use the M(get_url) module.



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

attribute :src

#validate_certs:yes, ...

Returns This only applies if using a https URL as the source of the file.,This should only set to C(no) used on personally controlled sites using self-signed certificate.,Prior to 2.2 the code worked as if this was set to C(yes).

Returns:

  • (:yes, :no, nil)

    This only applies if using a https URL as the source of the file.,This should only set to C(no) used on personally controlled sites using self-signed certificate.,Prior to 2.2 the code worked as if this was set to C(yes).



50
# File 'lib/ansible/ruby/modules/generated/files/unarchive.rb', line 50

attribute :validate_certs