Bug #36296
openTemplate render/macro for grub_pass fails
Description
When trying to add/configure grub pass at install time, it fail to render the template with a 500 server error.
From the logs the following messages (truncated) seem relevant
```
2023-04-12T18:29:42 [W|app|1be2ebbf] Error rendering the Kickstart default template
2023-04-12T18:29:42 [I|app|1be2ebbf] Backtrace for 'Error rendering the Kickstart default template' error (NoMethodError): undefined method `start_with?' for nil:NilClass
1be2ebbf | /usr/share/foreman/app/services/foreman/renderer/scope/macros/host_template.rb:127:in `grub_pass'
1be2ebbf | /opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.6/lib/safemode/scope.rb:37:in `method_missing'
1be2ebbf | Kickstart default:269:in `bind'
```
I've also attached a screenshot of the parameters configured.
We have set `encrypt_grub` to a boolean value of true and `grub_pass` to a string with the grub pass value.
Believe this stems from https://projects.theforeman.org/issues/32394 + https://github.com/theforeman/foreman/pull/8461
My first thought is that https://github.com/theforeman/foreman/blob/968998dbb73a975573d55f8e2d16c3437bf0bfaa/app/services/foreman/renderer/scope/macros/host_template.rb#L127 should be `host_param()` vs `host.<param>` but haven't tested.
Files