escapestudios/chef-newrelic — pull request #33 by sethcall (2013-09-18 19:34:48+00:00)
Title: * re-ordering declaration of out-of-order statements 

In chef 0.11.6, Ubuntu 12.04, I received these two errors:

```
* template[/etc/newrelic/nrsysmond.cfg] action restart
================================================================================
Error executing action `restart` on resource 'template[/etc/newrelic/nrsysmond.cfg]'
================================================================================

NameError
---------
Cannot find a resource for action_restart on ubuntu version 12.04
```
```
* remote_file[/etc/apt/sources.list.d/newrelic.list] action run
================================================================================
Error executing action `run` on resource 'remote_file[/etc/apt/sources.list.d/newrelic.list]'
================================================================================

NameError
---------
Cannot find a resource for action_run on ubuntu version 12.04
```

They we resolved by re-ordering the notified commands (execute in one case, service in another) above the code that was calling it.

This sounds almost like a Chef bug to me; it seems silly that order matters in this case. But I found that it did, so, the easiest thing to do is just re-order the offending statements.