简体   繁体   中英

How can I get Puppet to install .NET Framework 4.5?

So I am using Vagrant and Puppet on Mac OS X to instantiate and configure the Windows 2008 R2 Datacenter Full basebox found on http://www.vagrantbox.es/ (in VirtualBox) and I'm wondering if anyone has been able to successfully install .NET 4.5 to this image?

I found this module and I placed it in my project's /puppet/modules folder :

https://github.com/justinstoller/puppet-dotnet

All of my attempts to actually install .NET 4.0 or 4.5 result in permission errors.

I think this is because the Puppet Agent runs as "SYSTEM" and cannot make major changes to the operating system without elevated permissions.

Can anyone confirm this and provide a workaround? Preferably not involving building a custom basebox.

You are mixing class and resource declarations. Either use class (preferred):

class { 'dotnet':
  version => '4.5',
}

Or resource:

dotnet::installation { '4.5': }

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM