It seems that you should be using the switch /Featurename OR 
/Apply-Unattend NOT both, yet the puppet example is
 

dism { 'IIS-WebServer':
  ensure => present,
  answer => 'C:\answer\iis.xml',
}
https://forge.puppetlabs.com/puppetlabs/dism
 
 
I can see how to use this puppet module with the answer file, so i am going 
to try:
 
dism { 'NetFx3':
  ensure => present,
}
dism { 'IIS-WebServer':
ensure => present,
 
etc.....
 

On Friday, May 2, 2014 6:51:51 PM UTC+1, Rob Reynolds wrote:

> Can you verify /Apply-Unattend is a proper switch for that particular 
> feature? The error you are getting indicates it should not be used.
>
>
> On Fri, May 2, 2014 at 10:26 AM, Helen Paterson 
> <[email protected]<javascript:>
> > wrote:
>
>> Hi,
>>  
>> I'm getting the below error, when using an answer file with the forge 
>> puppet dism module
>>  
>>
>> Error: Execution of 'C:\Windows\sysnative\Dism.exe /online 
>> /Enable-Feature /Fea
>> ureName:IIS-WebServerRole /Apply-Unattend:c:\answer\iis_net.xml 
>> /NoRestart' ret
>> rned 87:
>> Deployment Image Servicing and Management tool
>> Version: 6.1.7600.16385
>> Image Version: 6.1.7600.16385
>> Error: 87
>> The apply-unattend option is not recognized in this context.
>> For more information, refer to the help.
>>
>>  
>>  
>> *This is my module*
>>  
>>
>> * class win7roles {  require win7roles::params      file {  
>> $win7roles::params::answer:      ensure  => directory,      recurse => 
>> true,       source  => "puppet:///modules/win7roles/answer",      force   
>> => true,      #copy files from puppet module to the local folder created 
>> above         }     dism { 'IIS-WebServerRole':  ensure => present,  answer 
>> => "${win7roles::params::answer}\\iis_net.xml",  require => 
>> File["${win7roles::params::answer}"],    #answer file create with windows 
>> system image manager(windows AIK) & windows 7 iso}                     }  
>>   class win7roles::params {   $answer ="c:\\answer"}  *
>>
>>  
>>
>>  -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Puppet Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected] <javascript:>.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/puppet-users/36c555a6-4c93-42f5-adba-416ddbaa715c%40googlegroups.com<https://groups.google.com/d/msgid/puppet-users/36c555a6-4c93-42f5-adba-416ddbaa715c%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> -- 
> Rob Reynolds
> Developer, Puppet Labs
>
> *Join us at **PuppetConf 2014 <http://puppetconf.com>**, September 
> 23-24 in San Francisco*
> *Register by May 30th to take advantage of the Early Adopter discount 
> <http://links.puppetlabs.com/puppetconf-early-adopter> **—**save $349!*
>  

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/40258a43-89fe-48d4-a7f1-ca590a0c8492%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to