community.sap_libs.sapcar_extract 模块 – 管理 SAP SAPCAR 归档文件
注意
此模块是 community.sap_libs 集合 (版本 1.4.2) 的一部分。
如果您正在使用 ansible
包,则可能已经安装了此集合。它不包含在 ansible-core
中。要检查它是否已安装,请运行 ansible-galaxy collection list
。
要安装它,请使用: ansible-galaxy collection install community.sap_libs
。
要在剧本中使用它,请指定: community.sap_libs.sapcar_extract
。
community.sap_libs 1.0.0 中的新增功能
概要
提供对使用 SAP 的 SAPCAR 二进制文件解包
sar
/car
文件并将信息提取回 Ansible 的支持。
参数
参数 |
注释 |
---|---|
SAPCAR 二进制文件的路径,例如 |
|
SAPCAR 解包 SAR 文件的目标位置。将创建缺少的文件夹。如果未提供此参数,它将在与 SAR 文件相同的文件夹中解包。 |
|
清单的名称。 默认值: |
|
SAR/CAR 文件的路径。 |
|
如果为 选项
|
|
安全库的路径,例如 |
|
如果为 选项
|
备注
注意
在
check_mode
中始终返回changed=true
。
示例
- name: Extract SAR file
community.sap_libs.sapcar_extract:
path: "~/source/hana.sar"
- name: Extract SAR file with destination
community.sap_libs.sapcar_extract:
path: "~/source/hana.sar"
dest: "~/test/"
- name: Extract SAR file with destination and download from webserver can be a fileshare as well
community.sap_libs.sapcar_extract:
path: "~/source/hana.sar"
dest: "~/dest/"
binary_path: "https://myserver/SAPCAR"
- name: Extract SAR file and delete SAR after extract
community.sap_libs.sapcar_extract:
path: "~/source/hana.sar"
remove: true
- name: Extract SAR file with manifest
community.sap_libs.sapcar_extract:
path: "~/source/hana.sar"
signature: true
- name: Extract SAR file with manifest and rename it
community.sap_libs.sapcar_extract:
path: "~/source/hana.sar"
manifest: "MyNewSignature.SMF"
signature: true