microsoft / PowerShell-DSC-for-Linux

PowerShell Desired State Configuration - for Linux
Other
339 stars 132 forks source link

Git-DsCResource not working after updating pwsh to 7.4 #913

Open AnassKartit opened 9 months ago

AnassKartit commented 9 months ago

After updating the github runners to 7.4 on ubuntu20.04 I get this error which prevents me from building mof packages: you can reproduce it by running the below powershell install for modules then get-dsc

$modules = @('GuestConfiguration', 'PSDesiredStateConfiguration', 'PSDscResources', 'nxtools')
  foreach ($module in $modules) {
    Install-Module -Name $module -Force -Scope CurrentUser
  }
  Get-DscResource

Get-DscResource: Line | 6 | Get-DscResource | ~~~ | Exception calling "LoadDefaultCimKeywords" with "2" argument(s): "Unable | to load shared library 'libmi' or one of its dependencies. In order to | help diagnose loading problems, consider using a tool like strace. If | you're using glibc, consider setting the LD_DEBUG environment variable: | /opt/microsoft/powershell/7/libmi.so: cannot open shared object file: No | such file or directory /opt/microsoft/powershell/7/liblibmi.so: cannot | open shared object file: No such file or directory | /opt/microsoft/powershell/7/libmi: cannot open shared object file: No | such file or directory /opt/microsoft/powershell/7/liblibmi: cannot open | shared object file: No such file or directory "

kasaxena5 commented 8 months ago

I am facing the same issue while installing it in powershell version 7.4, @AnassKartit what steps did you follow to mitigate it?