Ansible Azure - azure_rm_image

Hello team,
I’m trying to use Ansible to create snapshot from my azure VMS.
But every time that I use the azure_rm_image, return error.

ERROR! ‘azure_rm_image’ is not a valid attribute for a Play

Someone already use this?

Tks

Hello team,
I'm trying to use Ansible to create snapshot from my azure VMS.
But every time that I use the azure_rm_image, return error.

ERROR! 'azure_rm_image' is not a valid attribute for a Play

Someone already use this?

Tks

Please post your playbook.

Regards
          Racke

Hi Stefan,

Follow the script

Hi Stefan, follow the script:

  • name: Create an image from os disk via dict
    azure_rm_image:
    resource_group: RG-xxx
    name: srvfgl-xxxx-snapshot
    source:
    type: disks
    resource_group: RG-xxx
    name: srvfgl-xxxx_OsDisk_1_3d894cd33a2d4dfeb6aed9c1261cb391

What version of ansible are you using?