community / community.general / 2.5.9 / module / iso_create Generate ISO file with specified files or folders | "added in version" 0.2.0 of community.general" Authors: Diane Wang (@Tomorrow9) <dianew@vmware.com>community.general.iso_create (2.5.9) — module
Install with ansible-galaxy collection install community.general:==2.5.9
collections: - name: community.general version: 2.5.9
This module is used to generate ISO file with specified path of files.
- name: Create an ISO file community.general.iso_create: src_files: - /root/testfile.yml - /root/testfolder dest_iso: /tmp/test.iso interchange_level: 3
- name: Create an ISO file with Rock Ridge extension community.general.iso_create: src_files: - /root/testfile.yml - /root/testfolder dest_iso: /tmp/test.iso rock_ridge: 1.09
- name: Create an ISO file with Joliet support community.general.iso_create: src_files: - ./windows_config/Autounattend.xml dest_iso: ./test.iso interchange_level: 3 joliet: 3 vol_ident: WIN_AUTOINSTALL
udf: default: false description: - Whether to add UDF support to this ISO. - If set to C(True), then version 2.60 of the UDF spec is used. - If not specified or set to C(False), then no UDF support is added. type: bool joliet: choices: - 1 - 2 - 3 description: - Support levels and valid values are C(1), C(2), or C(3). - Level C(3) is by far the most common. - If not specified, then no Joliet support is added. type: int dest_iso: description: - The absolute path with file name of the new generated ISO file on local machine. - Will create intermediate folders when they does not exist. required: true type: path src_files: description: - This is a list of absolute paths of source files or folders which will be contained in the new generated ISO file. - Will fail if specified file or folder in C(src_files) does not exist on local machine. - 'Note: With all ISO9660 levels from 1 to 3, all file names are restricted to uppercase letters, numbers and underscores (_). File names are limited to 31 characters, directory nesting is limited to 8 levels, and path names are limited to 255 characters.' elements: path required: true type: list vol_ident: description: - The volume identification string to use on the new generated ISO image. type: str rock_ridge: choices: - '1.09' - '1.10' - '1.12' description: - Whether to make this ISO have the Rock Ridge extensions or not. - Valid values are C(1.09), C(1.10) or C(1.12), means adding the specified Rock Ridge version to the ISO. - If unsure, set C(1.09) to ensure maximum compatibility. - If not specified, then not add Rock Ridge extension to the ISO. type: str interchange_level: choices: - 1 - 2 - 3 - 4 default: 1 description: - The ISO9660 interchange level to use, it dictates the rules on the names of files. - Levels and valid values C(1), C(2), C(3), C(4) are supported. - The default value is level C(1), which is the most conservative, level C(3) is recommended. - ISO9660 file names at interchange level C(1) cannot have more than 8 characters or 3 characters in the extension. type: int
created_iso: description: Created iso file path. returned: on success sample: /path/to/test.iso type: str interchange_level: description: Configured interchange level. returned: on success sample: 3 type: int joliet: description: Configured Joliet support level. returned: on success sample: 3 type: int rock_ridge: description: Configured Rock Ridge version. returned: on success sample: '1.09' type: str source_file: description: Configured source files or directories list. elements: path returned: on success sample: - /path/to/file.txt - /path/to/folder type: list udf: description: Configured UDF support. returned: on success sample: false type: bool vol_ident: description: Configured volume identification string. returned: on success sample: OEMDRV type: str