![untar tar file untar tar file](https://prod.cdn.apps.splunk.com/media/public/screenshots/6e5b9dda-8c46-11e9-8250-0a4e45956b6e.jpeg)
The above playbook will unzip the file from the source location to the destination remote servers. name: Unzip the file from the remote location name: Ansible playbook for windows unzip module If the module is not available then you can download it from the galaxy.Īnsible-galaxy collection install community.windowsīelow is the simple playbook for windows untar (unzip). For the windows target, we need to use the win_unzip module. How untar works in Ansible?Īnsible unarchive module for non-windows target comes with the ansible-base and so it is included in the Ansible installations. Please note: the win_unzip module doesn’t use the remote_src parameter.
Untar tar file zip file#
recursively expands the zip file within the src directory.If the Zip file is password encrypted then this parameter is useful and it requires the PSCX module to be installed.There are other additional parameters like creates, seuser, serole, setype, selevel, unsafe_writes, validate_certs.įor the windows target src, dest, creates parameters remain the same as unarchive module and the additional parameters are as below. Permissions that the files or directories should have after unpacked (like 644, 777, etc).If set yes, it replaces the existing files that are newer than the files inside the archive.List of files or directories that need to be included in the unpacking process.List of files or directories that need to be excluded from the unpacking.Name of the group that should own the files/directory and same replicates (added) to the chown.name of the user that should own the files/directory after unpack and same replicates (added) to the chown.
![untar tar file untar tar file](https://linuxhint.com/wp-content/uploads/2021/06/view-tar-file-content-07.png)
For the ‘no’ value the path is on the local controller node.
![untar tar file untar tar file](https://i.ytimg.com/vi/iI-kqCa5apQ/maxresdefault.jpg)
Untar tar file archive#
If set ‘yes’ specifies that the source archive path is on the remote computer.Remote server absolute path where the archive is going to extract.If remote_src is ‘yes’ then the source path would be on the remote location otherwise the source path is on the local controller node. For working with the remote source need to specify the remote_src and this copy parameter is not helpful there. The default Option is Yes and it copies the files from the local controller to the remote host if specified yes or nothing specified.Web development, programming languages, Software testing & others Start Your Free Software Development Course