Project

General

Profile

Feature #16740

Host parameters should be available in templates using some macro

Added by Marek Hulán over 2 years ago. Updated 11 months ago.

Status:
Closed
Priority:
Normal
Category:
Templates
Target version:

Description

We should provide easy way to use all host parameters in templates to avoid calling internal method like @host.info['parameter'] or variable @parameters. Also there should be only one way so users don't have to check both info and @parameters. Ideally we'd add some macro to access it, which would also cache it while keeping it lazy (load on first time access).


Related issues

Related to Foreman - Bug #20931: Using host_params in parameters leads to @Safemode doesn't allow to access 'host_params' on #<Safemode::ScopeObject>@Closed
Related to Foreman - Bug #20968: invalid YAML in lookup keys can break db migrationsNew2017-09-17
Related to Foreman Remote Execution - Bug #22483: SSH key setup does not workClosed2018-02-01
Related to Foreman - Bug #23934: Still some @host.param leftoversClosed2018-06-14
Related to Foreman - Bug #24640: 1.17 migration causes array/hash values for parameters to turn into strings with escaped quotesClosed

Associated revisions

Revision 477b6b6b (diff)
Added by Ondřej Pražák over 2 years ago

Fixes #16740 - Access host params through macro

Revision 227ccb5f (diff)
Added by Marek Hulán almost 2 years ago

Refs #16740 - Update all templates to use params macros

Revision afe87279 (diff)
Added by Marek Hulán over 1 year ago

Refs #16740 - migration templates to use param macros

Revision 1551e92c (diff)
Added by Marek Hulán over 1 year ago

Refs #16740 - info was removed in 1.17

History

#1 Updated by Marek Hulán over 2 years ago

  • Description updated (diff)

#2 Updated by Marek Hulán over 2 years ago

  • Target version changed from 115 to 1.5.0

#3 Updated by Marek Hulán over 2 years ago

  • Target version changed from 1.5.0 to 1.4.2

#4 Updated by Ondřej Pražák over 2 years ago

  • Assignee set to Ondřej Pražák

#5 Updated by The Foreman Bot over 2 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/3983 added

#6 Updated by Marek Hulán over 2 years ago

  • Target version changed from 1.4.2 to 1.4.4

#7 Updated by Marek Hulán over 2 years ago

  • Target version changed from 1.4.4 to 1.10.1

#8 Updated by Ondřej Pražák over 2 years ago

  • Status changed from Ready For Testing to Closed
  • % Done changed from 0 to 100

#9 Updated by Dominic Cleal over 2 years ago

  • Legacy Backlogs Release (now unused) set to 209

#10 Updated by The Foreman Bot over 2 years ago

  • Pull request https://github.com/theforeman/community-templates/pull/343 added

#11 Updated by The Foreman Bot over 2 years ago

  • Pull request https://github.com/theforeman/foreman/pull/4187 added

#12 Updated by Marek Hulán almost 2 years ago

  • Target version changed from 1.10.1 to 1.17.0-RC2

#13 Updated by Ivan Necas over 1 year ago

  • Related to Bug #20931: Using host_params in parameters leads to @Safemode doesn't allow to access 'host_params' on #<Safemode::ScopeObject>@ added

#14 Updated by Ivan Necas over 1 year ago

  • Related to Bug #20968: invalid YAML in lookup keys can break db migrations added

#15 Updated by Marek Hulán over 1 year ago

  • Related to Bug #22483: SSH key setup does not work added

#16 Updated by Lukas Zapletal 11 months ago

  • Related to Bug #23934: Still some @host.param leftovers added

#17 Updated by Tomer Brisker 9 months ago

  • Related to Bug #24640: 1.17 migration causes array/hash values for parameters to turn into strings with escaped quotes added

Also available in: Atom PDF