voxpupuli / onceover

Your gateway drug to automated infrastructure testing with Puppet
141 stars 45 forks source link

No such file or directory error when running on Windows #299

Closed dylanratcliffe closed 3 years ago

dylanratcliffe commented 3 years ago

When running onceover on windows I get the following error:

ERROR    -> No such file or directory @ rb_sysopen - C:/Users/ADMINI~1/AppData/Local/Temp/1/d20210106-4692-1n0gfz3/puppetlabs-dsc-1.8.0/puppetlabs-dsc-1.8.0/lib/puppet_x/dsc_resources/OfficeOnlineServerDsc/DSCResources/MSFT_OfficeOnlineServerInstallLanguagePack/MSFT_OfficeOnlineServerInstallLanguagePack.schema.mof

Error while running: #<RuntimeError: r10k could not install all required modules>
dylanratcliffe commented 3 years ago

This is due to Windows path shortening. You can see that the path has been shortened ADMINI~1. In order to disable this you need to enable long paths:

#GPEdit location:  Configuration>Administrative Templates>System>FileSystem 
Set-ItemProperty 'HKLM:\System\CurrentControlSet\Control\FileSystem' -Name 'LongPathsEnabled' -value 1