I’ve been working with a project and we came across the need for working with PowerShell functions from a Windows Container, among then cmdlets from the Azure Storage module. Since the size (in GB) is a lot smaller for Nano Server (1 GB) vs Server Core (10 GB) we continued the development with functions compatible with PowerShell Core. Some time into development we noticed that the official PowerShell module for Azure (Azure.Storage) does not support usage from PowerShell Core. This is something I should have checked, but hindsight is 20/20 they say.
We searched the net far and wide for solutions, but we couldn’t find anything of the like (if any reader of this post actually know about a module, or when an official module is released, that would be great to hear about). This gave the idea to the ->AZStorage.Netcore <- module.
To install the module:
AZStorage.Netcore supports some basic cmdlets of the official module. The behaviour intentionally mimicks that of the official module to make usage easier for those that have some experience with it. It lacks a lot of cmdlets since it was only a handful of them that was needed for the original project, but more will be added. Or at least until another (hopefully an official one) has been released. Then the development will be discontinued.
Check out the source code at it’s ->repository<-. It also contains a more in depth readme for usage and about the project.
Article about PowerShell Core in a container: Build and run an application with or without .NET Core 2.0 or PowerShell Core 6. A link to the repository and it’s Dockerfiles to be found there.