|
42 | 42 | type: str
|
43 | 43 | content_type:
|
44 | 44 | description:
|
45 |
| - - Content type. |
46 |
| - - Required only for O(state=present). |
| 45 | + - Content type of the template. |
| 46 | + - Valid values are V(vztmpl) for LXC container templates, V(iso) for ISO disc images, and V(import) for harddisk images and Open Virtual Appliances (OVA). |
47 | 47 | type: str
|
48 | 48 | default: 'vztmpl'
|
49 |
| - choices: ['vztmpl', 'iso'] |
| 49 | + choices: ['vztmpl', 'import', 'iso'] |
50 | 50 | storage:
|
51 | 51 | description:
|
52 | 52 | - Target storage.
|
|
168 | 168 | url: ubuntu-20.04-standard_20.04-1_amd64.tar.gz
|
169 | 169 | checksum_algorithm: sha256
|
170 | 170 | checksum: 65d860160bdc9b98abf72407e14ca40b609417de7939897d3b58d55787aaef69
|
| 171 | +
|
| 172 | +- name: Upload new disk image template with minimal options |
| 173 | + community.proxmox.proxmox_template: |
| 174 | + node: uk-mc02 |
| 175 | + api_user: root@pam |
| 176 | + api_password: 1q2w3e |
| 177 | + api_host: node1 |
| 178 | + content_type: import |
| 179 | + src: debian-13-genericcloud-amd64.qcow2 |
| 180 | +
|
| 181 | +- name: Upload new ISO with minimal options |
| 182 | + community.proxmox.proxmox_template: |
| 183 | + node: uk-mc02 |
| 184 | + api_user: root@pam |
| 185 | + api_password: 1q2w3e |
| 186 | + api_host: node1 |
| 187 | + content_type: iso |
| 188 | + src: proxmox.iso |
171 | 189 | """
|
172 | 190 |
|
173 | 191 | import os
|
@@ -279,7 +297,7 @@ def main():
|
279 | 297 | src=dict(type='path'),
|
280 | 298 | url=dict(),
|
281 | 299 | template=dict(),
|
282 |
| - content_type=dict(default='vztmpl', choices=['vztmpl', 'iso']), |
| 300 | + content_type=dict(default='vztmpl', choices=['vztmpl', 'iso', 'import']), |
283 | 301 | storage=dict(default='local'),
|
284 | 302 | timeout=dict(type='int', default=30),
|
285 | 303 | force=dict(type='bool', default=False),
|
|
0 commit comments