![]() Just in case we need some extra command-line options we could specify in the “extra_opts” parameter. Other useful parameters are “include” and “exclude” that allows us to specify a subset of the archive to extract, specifically a list of inclusion or exclusion files or directories. In the “src” parameter we could also enter a URL, so the archive is going to be downloaded before being expanded. We could switch to a remote path enabling the “remote_src” properties. The “src” is quite special because is supposed to be a local path on the Ansible controller. The only mandatory parameters are “src” and “dst” which are the source and destination paths. The parameter list is pretty wide but this three are the most important options. extra_opts string - command-line options.include/exclude list - directory and file entries.validate_certs boolean - no/yes (https only). ![]() tar archive) for the Unix file format.įor Windows targets, use the _unzip. Please note that it requires a tarball (. It requires zipinfo, gtar and unzip command on target host. It unpacks one archive after (optionally) copying it from the local machine It works in a different variety of operating systems. It’s a module pretty stable and out for years. The full name is, which means that is part of the collection of modules “builtin” with ansible and shipped with it. Today we’re talking about the Ansible module unarchive. I’m Luca Berton and welcome to today’s episode of Ansible Pilot. I’m going to show you a live demo and some simple Ansible code. Donate How to extract an archive in Ansible?.Access the Complete Video Course and Learn Quick Ansible by 200+ Practical Lessons
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |