Add support for YAML anchors
Bug #1895614 reported by
Haw Loeung
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Content Cache Charm |
Fix Released
|
Wishlist
|
Haw Loeung |
Bug Description
Hi,
Per YAML spec[1], it supports anchors and references to those. This allows us to reduce duplication in certain things such as specifying backends (e.g. for multiple sites sharing the same set of K8s backends). We should support this, example:
| config: &TEST1 mytestvalue1
| config: &TEST2 mytestvalue2
|
| test:
| test1: *TEST1
| test2: *TEST2
So the charm should be able to support sites_yaml ignoring "config" and the rest is just straight YAML.
Related branches
~hloeung/content-cache-charm:yaml
- Paul Collins: Approve (lgtm)
- Canonical IS Reviewers: Pending requested
-
Diff: 84 lines (+15/-9)4 files modifiedreactive/content_cache.py (+2/-0)
tests/unit/files/config_test_config.txt (+7/-9)
tests/unit/test_haproxy.py (+2/-0)
tests/unit/test_nginx.py (+4/-0)
Changed in content-cache-charm: | |
assignee: | nobody → Haw Loeung (hloeung) |
status: | New → In Progress |
importance: | Undecided → Wishlist |
Changed in content-cache-charm: | |
status: | In Progress → Fix Committed |
Changed in content-cache-charm: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.