Project

General

Profile

Actions

Fix #12349

open

revisit packages/common_packages

Added by Dan Mick almost 9 years ago. Updated over 8 years ago.

Status:
Need More Info
Priority:
Normal
Assignee:
Category:
ansible
% Done:

0%

Source:
Development
Tags:
Backport:
Reviewed:
Affected Versions:
ceph-qa-suite:
Crash signature (v1):
Crash signature (v2):

Description

While reviewing docs for/trying to understand packages vs common_packages, I wondered if it would not be possible to use the same var name, "packages", at various levels of the tree, and have the more-specific levels do a list append; that way, each level defines which packages it knows to be necessary without the artificial split between "high-level" in common_packages and "low level" in packages (and the implication that there are only two levels of owners of package lists).

Something like "packages: {{packages|list}} + {{additional_packages|list}}"
was suggested. It's not clear if Ansible allows the RHS to refer to the prior value of a variable in order to reassign it to the LHS.

Actions #1

Updated by Dan Mick almost 9 years ago

  • Category set to ansible
  • Assignee set to Andrew Schoen
  • Source changed from other to Development
Actions #2

Updated by Dan Mick almost 9 years ago

  • Subject changed from revisit packages vs common_packages to revisit packages/common_packages
Actions #3

Updated by Andrew Schoen over 8 years ago

  • Status changed from New to In Progress

It doesn't seem we can use the same variable and append to it across multiple variable files.

This syntax does not appear to work:

packages: "{{ packages }} + {{ additional_packages }}" 

Jinja2 gets stuck in recursion and can't render the template.

Any other ideas on how to make common_packages and packages easier to understand?

Actions #4

Updated by Andrew Schoen over 8 years ago

  • Status changed from In Progress to Need More Info
Actions

Also available in: Atom PDF