Skip to content

Templates - #766

Closed
gak wants to merge 4 commits into
masterfrom
unknown repository
Closed

Templates#766
gak wants to merge 4 commits into
masterfrom
unknown repository

Conversation

@gak

@gakgak commented Jan 1, 2015

Copy link
Copy Markdown

Please see #761 for details.

Specifying a key of "template" within a service can refer to another yml
file causing the service to "override" another service in the template
file.
The value of template can either be a string, which refers to a service
of the same name in another yml file, or a dict consisting of two keys:
"service" and "path".
Signed-off-by: Gerald Kaszuba <gak@gak0.com>
There were a few bugs in my initial implementation:
- Infinite recursion when referring to the same template file.
Implementing a class and caching previously loaded yml files handles
that problem.
- Dictionaries that were updated in place where left "dirty". The
copy.copy fixes that.
- Incorrectly configured template yml files were not throwing fig
exceptions.
Signed-off-by: Gerald Kaszuba <gak@gak0.com>
Signed-off-by: Gerald Kaszuba <gak@gak0.com>
Signed-off-by: Gerald Kaszuba <gak@gak0.com>
@vdemeester

Copy link
Copy Markdown

As #761 is closed, maybe this one should be closed too (plus #1088 and other feature are more or less achieving this).

@gakgak closed this May 11, 2015
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@gak@vdemeester