Comments (7)
Hi @eric-tucker,
thanks for getting in touch! Sorry for the inconvenience the CHANGE_ME-changes have caused...
What about setting default['newrelic']['license'] to nil by default, instead of a random string (eg. "CHANGE_ME" or "REPLACE_WITH_REAL_KEY")?
Let me know what you think!
Kind regards,
David
from newrelic.
Something that is consistent and will not change.
To be honest, it should be nil by default so that I can set default values in a wrapper cookbook without having to use force_default as that prevents me from setting it in an environment file without using override.
If you leave node.newrelic.license at nil (undefined) that is the safest bet. Just don't set it at all. I want default[:newrelic][:license] = 'something' to work in a wrapper cookbook.
from newrelic.
+1 (will push these changes to master shortly)
from newrelic.
This is better and more consistent, but does force me to use force_default if I want to override in a wrapper cookbook (or I just set in environment files).
When I said nil by default, I actually meant undefined. As in no value if I referenced the hash using that index.
That being said, as long as there are no plans to change it again, I'm fine with this. Number one priority is consistency. :)
from newrelic.
Hi @eric-tucker,
there shouldn't be any need to use force_default when specifying the license attribute's value via...
default_attributes(
{
"newrelic" => {
"license" => "yournrlicensekey"
}
})
...in either a role or environment.
Re: plans to change it again
The only reason why I changed it from CHANGE_ME was that for some reason nrsysmond restarted just fine on Ubuntu when running tests without setting the license key. It failed when using the "REPLACE_WITH_REAL_KEY". Anyway, the current default value (nil) is not going to change anymore ;-)
Hope this helps!
Kind regards,
David
from newrelic.
Yup. force_default, however, is reserved for overriding in a wrapper cookbook where the wrapped cookbook set the value.
For now, I get by with checking for nil and overriding in the environment when I want it to be set. The reason I'm so concerned with this is I want to install newrelic automatically just by setting the value [away from the default]. Probably not a good practice, but I'd rather have that instant flexibility where my run list doesn't need to change: I just need to set an attribute to install newrelic.
from newrelic.
Ah ok, in that case: the default license-attribute will be (and will stay) nil :-)
Hope this helps!
from newrelic.
Related Issues (20)
- Newrelic dot APM agent doesnot upgrade HOT 4
- doesn't support strip_command_line parameter HOT 2
- Every node attribute used a default value to a property needs a `lazy { }` around it. HOT 6
- Cannot overwrite windows newrelic-infra agent source HOT 1
- Cloning resource attributes for service[newrelic-daemon] from prior resource HOT 1
- [agent_dotnet] Add support for enabling distributed tracing on the newrelic.config.erb template HOT 1
- Error executing action `enable` on resource 'newrelic_agent_infrastructure[Install]' is failing on debian7
- Default value of 'windows_checksum' in newrelic/resources/agent_infrastructure.rb does not match computed checksum HOT 1
- Recipe newrelic::java_agent fails install with the `Error executing action run on resource execute[newrelic_install_newrelic.jar]` HOT 2
- hello-world
- Hi world HOT 1
- Distributed Tracing feature in PHP Agent cookbook doesn't work
- add max_procs for newrelic_infra.yml
- Saleem A. H
- Compile Error on server_monitor.rb HOT 2
- "platform?" bug after ugprading newrelic version HOT 2
- Adding add event_queue_depth attribute to newrelic-infra.yml file is not there
- Cookbook failed on chef-client 17.8.25 HOT 2
- Hello World
- Please add Ubuntu 22.04 support, Ubuntu 20.04 fails with malformed repository line
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from newrelic.