~michael.nelson/charms/precise/elasticsearch/add-provides-elasticsearch

« back to all changes in this revision

Viewing changes to hooks/charmhelpers/contrib/templating/contexts.py

  • Committer: Michael Nelson
  • Date: 2014-03-06 10:56:27 UTC
  • mfrom: (10.1.5 nrpe-support)
  • Revision ID: michael.nelson@canonical.com-20140306105627-j5f8nku2tbw5qg32
MergeĀ nrpe-external-masterĀ support.

Show diffs side-by-side

added added

removed removed

Lines of Context:
39
39
    if 'relations' not in context:
40
40
        context['relations'] = {}
41
41
    if relation_type is not None:
 
42
        relation_type = relation_type.replace('-', '_')
42
43
        context['relations'][relation_type] = relations
43
44
 
44
45
 
67
68
    config['charm_dir'] = charm_dir
68
69
    config['local_unit'] = charmhelpers.core.hookenv.local_unit()
69
70
 
70
 
 
71
71
    # Don't use non-standard tags for unicode which will not
72
72
    # work when salt uses yaml.load_safe.
73
73
    yaml.add_representer(unicode, lambda dumper,