Pass the parent's registry into child stacks

We make sure that there is no infinite recursion by not repeating
a TemplateResource within a resources inheritance.

Change-Id: I1ffa66886923b15b52a8075089dd4042f0a55862
Fixes-bug: #1297396
Merge "Pass the parent's registry into child stacks"