Environment variable issue in chef


#1

I run chef-client that Sql installation on windows. During the task an environment variable will be updated in the windows System. That variable will be used by the chef-client in further execution of the same session.

But the issue here is, that environment variable is set to desired value but not reflecting the value in current session. Resulting in chef-client failure.


#2

You may be able to read the variable from the Registry HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment