I am having to installing everything necessary for all available nod-red nodes on a windows work machine. First of all I cant install Chocolatey which includes all of the necessary tools on my work machine due to security reasons with Chocolatey.
Now I am looking at these instructions for installing windows built tools under Environment setup and configuration but when i run: (npm install -g windows-build-tools) I get some npn warnings in power shell. I will include this screen shot.
I am wondering if I need to look at option 2 here and install visual studio build tools and python separately or figure out why I cant install the windows built tools that includes everything necessary?
By itself, Chocolatey doesn't do anything with regard to updating the underlying operating system. I believe that you may be referring to an issue with a version of Node which included a Boxstarter script, which installed a number of Chocolatey packages, which also had the side effect of performing a series of Windows Updates during the installation. This was an unfortunate situation, but it has been resolved - in other words, your IT dept are being a bit draconian.
You could always let nodejs installer the build tools then delete the Chocolatey stuff!
That said - are you actually intending of compiling native nodejs add-ons - OR - do you simply need a working node-red environment?
If you simply want node-js with the windows build tools, you could try the old npm installation method...
I am not sure how about the question on native nodjs add-ons. I need a working node-red environment, which I have but some of the nodes like node-red-contrib-modbus (node) - Node-RED
require the build tools.
Yes, the latest LTS version, it comes with build tools so you no longer need to install it separately.
Also, you may not be able to install Node-RED globally if you don't have local admin rights. If so, you may need to install locally. Have a look at my alternate installer on GitHub - you don't need to use it but it gives you the concepts for running locally.
I never recommend Chocolatey, it just gets in the way and installs things in odd places. Great when it works, a pain when it doesn't.
Sorry, just realised my statement wasn't clear and I've corrected it. I never recommend chocolatey. In any case, Windows now has its own package management and you should consider using that if anything. https://winget.run/
But for Node.js, I just either run the official Windows 64-bit installer or use winget.
Ok so back to my original problem if you are just using the standard node.js installer and do not select Chocolatey how are you installing the windows build tools or are you installing visual studion and pythong separately?
I seem to remember that it was an option on the installer. Quite probably by running via Choco if that is what you did, it didn't include the correct command-line options.
Pretty much any install of Python should work anyway, I've used lots of different ones but I now no longer recommend anything but the official Python 3 installer because all of the others including the Windows store, Iron Python, etc all come with issues and baggage that cause various difficulties. Python version management is nearly as painful as Java!
So I think what I would do if I were in your position would be to remove node.js and then install the official Python then reinstall node.js 16 or 18 manually from the official installer. While you shouldn't need to do the Python install, it can be very useful in other things anyway.