Refactored namenode and datanode recipe

* Bug fixes
* Simplified
* Works