Giter Club home page Giter Club logo

Comments (14)

dhoer avatar dhoer commented on September 13, 2024

Please let me know if v3.0.2 fixed this issue

from nssm.

emachnic avatar emachnic commented on September 13, 2024

Hi @dhoer, tried with version 3.0.2 and this is still an issue. Thanks for looking into it.

from nssm.

dhoer avatar dhoer commented on September 13, 2024

What platform and chef-client version is this occurring on?

from nssm.

emachnic avatar emachnic commented on September 13, 2024

This is on Windows Server 2012R2 with Chef 12.21.1

from nssm.

dhoer avatar dhoer commented on September 13, 2024

Does changing the attribute from ENV['WINDIR'] to '%WINDIR%' fix the issue?

from nssm.

dhoer avatar dhoer commented on September 13, 2024

From #chef irc chat: <@cheeseplus> dhoer: based on my reading of that that, the place they're trying to put the file doesn't already exist

from nssm.

Annih avatar Annih commented on September 13, 2024

IMHO this is not completly related to nssm cookbook but more due to consul cookbook weird usage.
In consul cookbook the nssm.install_location value is overridden from ENV['WINDIR'] to %WINDIR% (https://github.com/johnbellone/consul-cookbook/blob/master/recipes/default.rb#L7)

I agreeat that it appears that a recent change in nssm broke consul behavior, but the faulty line in consul cookbook shouldn't be here :)

I'm preparing a PR for the consul cookbook to be compatible with #21

from nssm.

aprice avatar aprice commented on September 13, 2024

Has that PR been submitted to consul cookbook?

from nssm.

Annih avatar Annih commented on September 13, 2024

Not yet, I'm waiting for @dhoer to release the 4.0 version of nssm cookbook ^^

from nssm.

aprice avatar aprice commented on September 13, 2024

Understandable - do you know offhand what the last working pin would be? nssm 3.0.0 + consul 3.0.0? Looks like the referenced line (overriding install_location to %WINDIR%) has been around a long time.

from nssm.

axelrtgs avatar axelrtgs commented on September 13, 2024

the change from %WINDIR% to ENV['WINDIR'] was because on some systems it was failing to expand the %WINDIR% into the correct path. In ruby the correct method for getting environment variables is using the ENV[] syntax as that will work reliably.

This is from my experience in using the environment variables.

from nssm.

axelrtgs avatar axelrtgs commented on September 13, 2024

@aprice Also to answer your question, from what i can tell i think this issue might be chef version dependent because the attribute is being used directly in the remote_file resource (in versions <=3.0.1) and the paths no longer expanding may have been a change in more recent chef versions and how they copy files which broke the nssm cookbook and required the change to the proper ruby method for expanding that environment variable. 3.0.1 should be working otherwise the behavior of remote_file may have changed in chef.

@Annih the change in the consul cookbook to properly expand the environment attribute shouldn't depend on the release of 4.0 since the changes in 4.0 dont fix or break anything in that regard.

from nssm.

Annih avatar Annih commented on September 13, 2024

@axelrtgs I'm not saying the fix should depends on v4.0. I'm just saying I'll not provide a PR on consul cookbook until v4.0 is released :)

from nssm.

axelrtgs avatar axelrtgs commented on September 13, 2024

Makes sense, i was just thinking more form the interest of getting it fixed sooner but i also understand wanting to wait for the latest release

from nssm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.