Title: Microsoft.Management.Infrastructure NuGet package missing dependencies · Issue #4562 · PowerShell/PowerShell · GitHub
Open Graph Title: Microsoft.Management.Infrastructure NuGet package missing dependencies · Issue #4562 · PowerShell/PowerShell
X Title: Microsoft.Management.Infrastructure NuGet package missing dependencies · Issue #4562 · PowerShell/PowerShell
Description: I'm writing a ASP.NET Core web app that requires accessing CIM information/methods. Microsoft.Management.Infrastructure v4.0.0, available via NuGet, is not .NET Core compatible, so naturally I was curious how CIM works in PowerShell. I f...
Open Graph Description: I'm writing a ASP.NET Core web app that requires accessing CIM information/methods. Microsoft.Management.Infrastructure v4.0.0, available via NuGet, is not .NET Core compatible, so naturally I was ...
X Description: I'm writing a ASP.NET Core web app that requires accessing CIM information/methods. Microsoft.Management.Infrastructure v4.0.0, available via NuGet, is not .NET Core compatible, so naturally I ...
Opengraph URL: https://github.com/PowerShell/PowerShell/issues/4562
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Microsoft.Management.Infrastructure NuGet package missing dependencies","articleBody":"I'm writing a ASP.NET Core web app that requires accessing CIM information/methods. Microsoft.Management.Infrastructure v4.0.0, available via NuGet, is not .NET Core compatible, so naturally I was curious how CIM works in PowerShell. I found that you are using a powershell-core ```https://powershell.myget.org/F/powershell-core/api/v3/index.json``` respository to host Microsoft.Management.Infrastructure v1.0.0-alpha06, so I added that to my project and everything seemed fine until I try to use any code from MMI.\r\n\r\nI found a related issue #1204, but that issue was addressed for situations where MMI is used within the context of PowerShell. It looks like the solution was not applied directly to the MMI assembly itself.\r\n\r\nI realize that the intention for the PowerShell Core version of MMI is to be used within the context of PowerShell, but it'd be much appreciated if the library was compatible with other use cases like ASP.NET Web Applications. \r\n\r\nSteps to reproduce\r\n------------------\r\nI've posted a [sample project](https://github.com/jaredcatkinson/MMI_Issue) so you can see how I am attempting to use the library.\r\n\r\nExpected behavior\r\n-----------------\r\ncalc.exe runs on the remote host (localhost in this case). This is the result on Windows, but not Linux.\r\n\r\nActual behavior\r\n---------------\r\nThe application crashes with the following error:\r\n```\r\nUnable to load DLL 'libmi.so': The specified module could not be found.\r\n```\r\n\r\nI found an issue (#2120) that talks about libmi.so being part of OMI, so I installed OMI and borrowed it. This fixed the first issue, but another issue came up with the following error:\r\n```none\r\nCould not find any resources appropriate for the specified culture or the neutral culture. Make sure \"Microsoft.Management.Infrastructure.Strings.resources\" was correctly embedded or linked into assembly \"Microsoft.Management.Infrastructure\" at compile time, or that all the satellite assemblies required are loadable and fully signed.\r\n```\r\n\r\nEnvironment data\r\n----------------\r\nThe goal is to Dockerize this app, so the test system I am using is Docker's [microsoft/aspnetcore](https://hub.docker.com/r/microsoft/aspnetcore/) Image (Debian Jessie).\r\n```\r\nuname -a\r\nLinux ace-app 4.9.36-moby #1 SMP Wed Jul 12 15:29:07 UTC 2017 x86_64 GNU/Linux\r\n```\r\n","author":{"url":"https://github.com/jaredcatkinson","@type":"Person","name":"jaredcatkinson"},"datePublished":"2017-08-11T23:17:40Z","url":"https://github.com/PowerShell/PowerShell/issues/4562"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:547e427d-2008-ccf7-68ab-665425dc1fba |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A1E6:2AABF1:25A5E0C:34BD72F:6AFD47F7 |
| html-safe-nonce | a116eeaf503b1c64d9401ec9579a6b9a848c896a9431d4ab611fa0bae50b5178 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBMUU2OjJBQUJGMToyNUE1RTBDOjM0QkQ3MkY6NkFGRDQ3RjciLCJ2aXNpdG9yX2lkIjoiNTg5MzY0MDU2NTg3Nzk4MzIyMyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 987058b6a3cffc8289124cff43dfcc8a983f5b1e8398ab44fe2d9b9459c60100 |
| hovercard-subject-tag | issue:249769142 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/PowerShell/PowerShell/4562/issue_layout |
| twitter:image | https://opengraph.githubassets.com/7fb9c7c21c1ce9f51285eeec5c7bf137f7efe16a03429943cf1d6029b15975fc/PowerShell/PowerShell/issues/4562 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/7fb9c7c21c1ce9f51285eeec5c7bf137f7efe16a03429943cf1d6029b15975fc/PowerShell/PowerShell/issues/4562 |
| og:image:alt | I'm writing a ASP.NET Core web app that requires accessing CIM information/methods. Microsoft.Management.Infrastructure v4.0.0, available via NuGet, is not .NET Core compatible, so naturally I was ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | jaredcatkinson |
| hostname | github.com |
| expected-hostname | github.com |
| None | bdbacc25b921224ff0befcb9e629560a1255be51aec9991d6e3f95b5e9151474 |
| turbo-cache-control | no-preview |
| go-import | github.com/PowerShell/PowerShell git https://github.com/PowerShell/PowerShell.git |
| octolytics-dimension-user_id | 11524380 |
| octolytics-dimension-user_login | PowerShell |
| octolytics-dimension-repository_id | 49609581 |
| octolytics-dimension-repository_nwo | PowerShell/PowerShell |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 49609581 |
| octolytics-dimension-repository_network_root_nwo | PowerShell/PowerShell |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 556dd37bb0aceffb25724e151b5d858b3265b40b |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width