blog.kaniski.eu I just wanna learn!

23Sep/200

Network share feeds in WAC

You know about (and actively using) the Windows Admin Center (WAC), right?! ūüėČ

While it's great for managing your Microsoft infrastructure, it can also be extended with different extensions. You can even write and use your internal, custom extensions, which do... well, whatever you make them do. And you can read all about that here.

But let's go back to the subject of today's post - extensions can be installed via different feeds, either official or unofficial, provided by Microsoft or 3rd-party. You can easily add new feeds or remove existent by providing the feed location, which can be either a NuGet feed URL or a file share location, as stated in the official docs.

Using a file share location is easy:

  • you choose/create a folder:

  • share it (\\<my_server_name>\WACExtensions in my case):

  • and add it to your feeds - I'll use the "PowerShell way":

But no!

My feed seems to be added successfully, but it's not showing in the list!

You can try the same through the web interface - it's almost the same (OK, you'll get the errors):

And permissions are fine, don't worry. ūüėČ

Why's that?!

The catch here is that we added an empty folder/share - when adding this share, WAC intelligently looked into the folder, found nothing and (successfully) didn't add our share to the feed list, as it's empty. And yes, it also forgot to mention it when using PowerShell.

So, what can be done?

The workaround/solution is rather simple - just make sure you don't add an empty feed/folder.

Just for fun - I've downloaded the HPE Extension for WAC, moved it into the WACExtensions shared folder and tried to add the feed again:

And - it worked! ūüėä

Cheers!

8Sep/200

Having fun with Helm and file encoding

Had some spare time, so I've tried to learn a bit more about Helm, the package manager for Kubernetes.

I've decided to follow the relatively new Pluralsight course called - Kubernetes Package Administration with Helm, done by my MVP colleague Andrew Pruski. And it was great - not too long, clear and easy to follow, with only a handful of prerequisites if you want to follow along! Great job!

Of course, there is also the nice, official documentation.

But why am I writing this post?

I was normally following this course on my Windows 10 laptop, using Visual Studio Code, as suggested, and also using PowerShell terminal, with Helm v3.3.1.

It all went well until the part when we are creating our Helm Chart, more specifically - when we're filling up our deployment.yaml and service.yaml files. Suggested (and simplest) method is to use the simple output redirection (with ">"), like this:

But, this gave me the following error when trying to deploy the chart:

It's quite obvious - Helm works with UTF-8, and my .yaml files seem to be encoded differently. Quick look at the bottom of my VSCode confirms it:

How can I fix it?

As I'm using PowerShell, it's pretty easy - instead of doing the simple output redirection (">"), I pipe output to Out-File cmdlet with -Encoding UTF8 option, in all cases, which takes care of the encoding (and sets it to UTF-8 with BOM, which is just fine for Helm):

So, long story short - if you run into the error above ("Error: unable to build kubernetes objects from release manifest: error parsing : error converting YAML to JSON: yaml: invalid leading UTF-8 octet"), remember to check your file's encoding (and change it to UTF-8, if needed)! ūüôā

Cheers!

P.S. Thanks to good people at Pluralsight for providing me a complimentary subscription!