The module azure_rm_virtualmachine has fields for plan information. Module azure_rm_virtualmachinescaleset needs to have them and forward them when creating a VM with an image that requires plan info to be specified. The CIS hardened images from the Azure Marketplace is a prime example.

if self.zones != vmss_dict['zones']:
                    self.log("CHANGED: virtual machine scale sets {0} zones".format(self.name))
                    differences.append('Zones')
                    changed = True
                    vmss_dict['zones'] = self.zones
                nicConfigs = vmss_dict['properties']['virtualMachineProfile']['networkProfile']['networkInterfaceConfigurations']
                backend_address_pool = nicConfigs[0]['properties']['ipConfigurations'][0]['properties'].get('loadBalancerBackendAddressPools', [])
                backend_address_pool += nicConfigs[0]['properties']['ipConfigurations'][0]['properties'].get('applicationGatewayBackendAddressPools', [])
                lb_or_ag_id = None
                if (len(nicConfigs) != 1 or len(backend_address_pool) != 1):
                    support_lb_change = False  
                    self.module.warn('Updating more than one load balancer on VMSS is currently not supported')
                else:
                    if load_balancer:
                        lb_or_ag_id = "{0}/".format(load_balancer.id)
                    elif application_gateway:
                        lb_or_ag_id = "{0}/".format(application_gateway.id)
                    backend_address_pool_id = backend_address_pool[0].get('id')
                    if bool(lb_or_ag_id) != bool(backend_address_pool_id) or not backend_address_pool_id.startswith(lb_or_ag_id):
                        differences.append('load_balancer')
                        changed = True
                if self.custom_data:
                    if self.custom_data != vmss_dict['properties']['virtualMachineProfile']['osProfile'].get('customData'):
                        differences.append('custom_data')
                        changed = True
                        vmss_dict['properties']['virtualMachineProfile']['osProfile']['customData'] = self.custom_data
                self.differences = differences
            elif self.state == 'absent':
                self.log("CHANGED: virtual machine scale set {0} exists and requested state is 'absent'".format(self.name))
                results = dict()