Actions
Bug #18906
closedAdd advanced jinja2 template example for main IP address
Pull Request:
Severity:
UX impact:
User visibility:
Effort required:
Priority:
0
Name check:
To do
Fix check:
Checked
Regression:
Description
Add an example of template logic to chose an IP by interface name priority.
{%- if 'bond0' in vars.sys.interfaces %} # 'bond0' in vars.sys.interfaces {%- set my_ip = vars.sys['ipv4[bond0]'] %} {%- elif 'eth0' in vars.sys.interfaces %} # Found eth0 as default interface {%- set my_ip = vars.sys['ipv4[eth0]'] %} {%- else %} # Not found bond0 or eth0, using default sys.ipv4 {%- set my_ip = vars.sys.ipv4 %} {%- endif %}
Updated by Alexis Mousset almost 4 years ago
- Status changed from New to In progress
- Assignee set to Alexis Mousset
Updated by Alexis Mousset almost 4 years ago
- Status changed from In progress to Pending technical review
- Assignee changed from Alexis Mousset to François ARMAND
- Pull Request set to https://github.com/Normation/rudder-doc/pull/817
Updated by Alexis Mousset almost 4 years ago
- Status changed from Pending technical review to Pending release
Applied in changeset rudder-doc|cd137eeafd5a8466a097fde1fa806df51c89e9e2.
Updated by Alexis Mousset almost 4 years ago
- Fix check changed from To do to Checked
Updated by Vincent MEMBRÉ almost 4 years ago
- Status changed from Pending release to Released
This bug has been fixed in Rudder 6.2.3 which was released today.
Actions