def METHOD_NAME(provider, system, versions, runtime, dryrun=False, save=False):
    cmd = ['goss', '-g', 'packer/goss/goss.yaml', '--vars', 'packer/goss/goss-vars.yaml']
    vars = {'OS': system, 'PROVIDER': provider,
            'OS_VERSION': versions['os'],
            'containerd_version': versions['containerd'],
            'docker_ee_version': versions['docker'],
            'distribution_version': versions['os'],
            'kubernetes_version': versions['k8s'],
            'kubernetes_deb_version': versions['k8s_deb'],
            'kubernetes_rpm_version': versions['k8s_rpm'],
            'kubernetes_source_type': 'pkg',
            'kubernetes_cni_version': versions['cni'],
            'kubernetes_cni_deb_version': versions['cni_deb'],
            'kubernetes_cni_rpm_version': versions['cni_rpm'],
            'kubernetes_cni_source_type': 'pkg',
            'runtime': runtime,
            'pause_image': versions['pause']}
    if system == "windows" and versions.get('ssh_url') is not None:
        vars['ssh_source_url'] = versions['ssh_url']
    # Build command
    cmd.extend(['--vars-inline', json.dumps(vars), 'render'])
    print('\nGenerating os: %s, provider: %s, runtime: %s' % (system, provider, runtime))
    print(cmd)
    # Run command with output going to file
    if not dryrun:
        if save:
            out_dir = os.path.join(root_path, 'packer', 'goss')
            out_filename = '%s-%s-%s-goss-spec.yaml' % (provider,
                                                        system.replace(' ', '-'), versions['k8s'])
            out_filename = os.path.join(out_dir, out_filename)
            with open(out_filename, 'w') as f:
                subprocess.run(cmd, cwd=root_path, stdout=f, check=True)
        else:
            subprocess.run(cmd, cwd=root_path, check=True)