Foreman 1.15.1 error rendering the Kickstart default template (subnet6 issue)

I am running foreman 1.15.1 and generally things are working fine but when
I attempt to assign a ipv6 subnet/ip to a host I get the following error
when host is trying to get it's unattended token.

There was an error rendering the Kickstart default template: ERF42-7327
[Foreman::Exception]: The snippet 'kickstart_ifcfg_generic_interface' threw
an error: Safemode doesn't allow to access 'subnet6' on
#<Safemode::ScopeObject>

If I remove the ipv6 subnet/ip it builds fine. We use
location/organizations so I verified that the subnet is allowed on both
loc/org and it is.The subnet config uses EUI-64 option. For this test we
were using the "Kickstart default" that comes with foreman unaltered.

Is there another knob to fiddle with on this I am missing perhaps?

The foreman logs report the following.

2017-10-05 15:34:48 b08dc01b [app] [W] There was an error rendering the
Kickstart default template:
> ActionView::Template::Error: ERF42-7327 [Foreman::Exception]: The
snippet 'kickstart_ifcfg_generic_interface' threw an error: Safemode
doesn't allow to access 'subnet6' on #<Safemode::ScopeObject>
>
/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode/scope.rb:39:in
method_missing&#39; &gt; kickstart_ifcfg_generic_interface:80:inbind'
>
/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:51:in
eval&#39; &gt; /opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:51:ineval'
> /usr/share/foreman/lib/foreman/renderer.rb:56:in render_safe&#39; &gt; /usr/share/foreman/lib/foreman/renderer.rb:175:inunattended_render'
> /usr/share/foreman/lib/foreman/renderer.rb:121:in snippet&#39; &gt; /opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode/scope.rb:37:inmethod_missing'
> kickstart_networking_setup:93:in block in bind&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/relation/delegation.rb:46:ineach'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/relation/delegation.rb:46:in
each&#39; &gt; /opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode/jail.rb:31:inmethod_missing'
> kickstart_networking_setup:81:in bind&#39; &gt; /opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:51:ineval'
>
/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:51:in
eval&#39; &gt; /usr/share/foreman/lib/foreman/renderer.rb:56:inrender_safe'
> /usr/share/foreman/lib/foreman/renderer.rb:175:in unattended_render&#39; &gt; /usr/share/foreman/lib/foreman/renderer.rb:121:insnippet'
>
/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode/scope.rb:37:in
method_missing&#39; &gt; ISS - Kickstart default:223:inbind'
>
/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:51:in
eval&#39; &gt; /opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:51:ineval'
> /usr/share/foreman/lib/foreman/renderer.rb:56:in render_safe&#39; &gt; /usr/share/foreman/lib/foreman/renderer.rb:175:inunattended_render'
> inline template:1:in _inline_template__3026775553150963812_77721940&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/template.rb:145:inblock in render'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:166:in
instrument&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/template.rb:333:ininstrument'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/template.rb:143:in
render&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/renderer/template_renderer.rb:54:inblock (2 levels) in render_template'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/renderer/abstract_renderer.rb:39:in
block in instrument&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:164:inblock in instrument'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/notifications/instrumenter.rb:20:in
instrument&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:164:ininstrument'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/renderer/abstract_renderer.rb:39:in
instrument&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/renderer/template_renderer.rb:53:inblock in render_template'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/renderer/template_renderer.rb:61:in
render_with_layout&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/renderer/template_renderer.rb:52:inrender_template'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/renderer/template_renderer.rb:14:in
render&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/renderer/renderer.rb:46:inrender_template'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/renderer/renderer.rb:27:in
render&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/rendering.rb:100:in_render_template'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/streaming.rb:217:in
_render_template&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/rendering.rb:83:inrender_to_body'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/rendering.rb:32:in
render_to_body&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/renderers.rb:37:inrender_to_body'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_controller/rendering.rb:25:in
render&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/rendering.rb:16:inrender'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/instrumentation.rb:44:in
block (2 levels) in render&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/core_ext/benchmark.rb:12:inblock in ms'
> /opt/rh/rh-ruby22/root/usr/share/ruby/benchmark.rb:303:in realtime&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/core_ext/benchmark.rb:12:inms'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/instrumentation.rb:44:in
block in render&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/instrumentation.rb:87:incleanup_view_runtime'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/railties/controller_runtime.rb:25:in
cleanup_view_runtime&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/instrumentation.rb:43:inrender'
> /usr/share/foreman/app/controllers/unattended_controller.rb:218:in
safe_render&#39; &gt; /usr/share/foreman/app/controllers/unattended_controller.rb:74:inrender_template'
> /usr/share/foreman/app/controllers/unattended_controller.rb:47:in
host_template&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/implicit_render.rb:4:insend_action'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_controller/base.rb:198:in
process_action&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/rendering.rb:10:inprocess_action'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_controller/callbacks.rb:20:in
block in process_action&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:117:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:117:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:555:inblock (2 levels) in compile'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:in
block (2 levels) in around&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
block (2 levels) in halting&#39; &gt; /usr/share/foreman/app/controllers/concerns/application_shared.rb:15:inset_timezone'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:432:in
block in make_lambda&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
block in halting&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
block in around&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:inblock (2 levels) in around'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:inblock (2 levels) in halting'
> /usr/share/foreman/app/models/concerns/foreman/thread_session.rb:32:in
clear_thread&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:432:inblock in make_lambda'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:inblock in halting'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:inblock in around'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:in
block (2 levels) in around&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
block (2 levels) in halting&#39; &gt; /usr/share/foreman/app/controllers/concerns/foreman/controller/topbar_sweeper.rb:12:inset_topbar_sweeper_controller'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:432:in
block in make_lambda&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
block in halting&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
block in around&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:498:inblock (2 levels) in around'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:313:inblock (2 levels) in halting'
>
/opt/theforeman/tfm/root/usr/share/gems/gems/audited-4.4.1/lib/audited/sweeper.rb:14:in
around&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:455:inpublic_send'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:455:in
block in make_lambda&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:312:in
block in halting&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:497:in
block in around&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:92:inrun_callbacks'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:778:in
_run_process_action_callbacks&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:81:inrun_callbacks'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_controller/callbacks.rb:19:in
process_action&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/rescue.rb:29:inprocess_action'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/instrumentation.rb:32:in
block in process_action&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:164:inblock in instrument'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/notifications/instrumenter.rb:20:in
instrument&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:164:ininstrument'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/instrumentation.rb:30:in
process_action&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/params_wrapper.rb:250:inprocess_action'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/railties/controller_runtime.rb:18:in
process_action&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_controller/base.rb:137:inprocess'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_view/rendering.rb:30:in
process&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal.rb:196:indispatch'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal/rack_delegation.rb:13:in
dispatch&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_controller/metal.rb:237:inblock in action'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/routing/route_set.rb:74:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/routing/route_set.rb:74:indispatch'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/routing/route_set.rb:43:in
serve&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/journey/router.rb:43:inblock in serve'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/journey/router.rb:30:in
each&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/journey/router.rb:30:inserve'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/routing/route_set.rb:815:in
call&#39; &gt; /opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.4.0/lib/apipie/static_dispatcher.rb:65:incall'
>
/opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.4.0/lib/apipie/extractor/recorder.rb:132:in
call&#39; &gt; /opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.4.0/lib/apipie/middleware/checksum_in_headers.rb:27:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/etag.rb:24:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/conditionalget.rb:25:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/head.rb:13:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/params_parser.rb:27:incall'
> /usr/share/foreman/lib/middleware/catch_json_parse_errors.rb:8:in call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/flash.rb:260:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/session/abstract/id.rb:225:in
context&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/rack-1.6.2/lib/rack/session/abstract/id.rb:220:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/cookies.rb:560:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/query_cache.rb:36:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:653:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/callbacks.rb:29:inblock in call'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:88:in
__run_callbacks__&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:778:in_run_call_callbacks'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:81:in
run_callbacks&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/callbacks.rb:27:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/remote_ip.rb:78:in
call&#39; &gt; /opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/debug_exceptions.rb:17:incall'
>
/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_dispatch/middleware/show_exceptio

Hello,

it looks like Feature #14664: Add IPv6 Subnet to Host, Hostgroup and Nic Models - Foreman which was fixed in
1.13, subnet6 is among allowed attributes. The error message might be
misleading, double check the host interfaces. You can debug the snippet using
the preview button when editing the template.

··· -- Marek

On čtvrtek 5. října 2017 17:54:16 CEST Mike Wilson wrote:

I am running foreman 1.15.1 and generally things are working fine but when
I attempt to assign a ipv6 subnet/ip to a host I get the following error
when host is trying to get it’s unattended token.

There was an error rendering the Kickstart default template: ERF42-7327
[Foreman::Exception]: The snippet ‘kickstart_ifcfg_generic_interface’ threw
an error: Safemode doesn’t allow to access ‘subnet6’ on
#Safemode::ScopeObject

If I remove the ipv6 subnet/ip it builds fine. We use
location/organizations so I verified that the subnet is allowed on both
loc/org and it is.The subnet config uses EUI-64 option. For this test we
were using the “Kickstart default” that comes with foreman unaltered.

Is there another knob to fiddle with on this I am missing perhaps?

The foreman logs report the following.

2017-10-05 15:34:48 b08dc01b [app] [W] There was an error rendering the

Kickstart default template:

ActionView::Template::Error: ERF42-7327 [Foreman::Exception]: The

snippet ‘kickstart_ifcfg_generic_interface’ threw an error: Safemode
doesn’t allow to access ‘subnet6’ on #Safemode::ScopeObject

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode/sco
pe.rb:39:in `method_missing’

kickstart_ifcfg_generic_interface:80:in `bind’

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:
51:in `eval’

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:
51:in `eval’

/usr/share/foreman/lib/foreman/renderer.rb:56:in render_safe' /usr/share/foreman/lib/foreman/renderer.rb:175:inunattended_render’
/usr/share/foreman/lib/foreman/renderer.rb:121:in `snippet’

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode/sco
pe.rb:37:in `method_missing’

kickstart_networking_setup:93:in `block in bind’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_
record/relation/delegation.rb:46:in `each’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_
record/relation/delegation.rb:46:in `each’

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode/jai
l.rb:31:in `method_missing’

kickstart_networking_setup:81:in `bind’

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:
51:in `eval’

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:
51:in `eval’

/usr/share/foreman/lib/foreman/renderer.rb:56:in render_safe' /usr/share/foreman/lib/foreman/renderer.rb:175:inunattended_render’
/usr/share/foreman/lib/foreman/renderer.rb:121:in `snippet’

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode/sco
pe.rb:37:in `method_missing’

ISS - Kickstart default:223:in `bind’

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:
51:in `eval’

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode.rb:
51:in `eval’

/usr/share/foreman/lib/foreman/renderer.rb:56:in render_safe' /usr/share/foreman/lib/foreman/renderer.rb:175:inunattended_render’
inline template:1:in `_inline_template__3026775553150963812_77721940’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/template.rb:145:in `block in render’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/notifications.rb:166:in `instrument’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/template.rb:333:in `instrument’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/template.rb:143:in `render’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/renderer/template_renderer.rb:54:in `block (2 levels) in render_template’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/renderer/abstract_renderer.rb:39:in `block in instrument’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/notifications.rb:164:in `block in instrument’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/notifications/instrumenter.rb:20:in `instrument’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/notifications.rb:164:in `instrument’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/renderer/abstract_renderer.rb:39:in `instrument’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/renderer/template_renderer.rb:53:in `block in render_template’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/renderer/template_renderer.rb:61:in `render_with_layout’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/renderer/template_renderer.rb:52:in `render_template’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/renderer/template_renderer.rb:14:in `render’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/renderer/renderer.rb:46:in `render_template’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/renderer/renderer.rb:27:in `render’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/rendering.rb:100:in `_render_template’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_co
ntroller/metal/streaming.rb:217:in `_render_template’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionview-4.2.5.1/lib/action_vi
ew/rendering.rb:83:in `render_to_body’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_co
ntroller/metal/rendering.rb:32:in `render_to_body’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_co
ntroller/metal/renderers.rb:37:in `render_to_body’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_
controller/rendering.rb:25:in `render’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_co
ntroller/metal/rendering.rb:16:in `render’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_co
ntroller/metal/instrumentation.rb:44:in `block (2 levels) in render’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/core_ext/benchmark.rb:12:in `block in ms’

/opt/rh/rh-ruby22/root/usr/share/ruby/benchmark.rb:303:in `realtime’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/core_ext/benchmark.rb:12:in `ms’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_co
ntroller/metal/instrumentation.rb:44:in `block in render’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_co
ntroller/metal/instrumentation.rb:87:in `cleanup_view_runtime’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activerecord-4.2.5.1/lib/active_
record/railties/controller_runtime.rb:25:in `cleanup_view_runtime’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_co
ntroller/metal/instrumentation.rb:43:in `render’

/usr/share/foreman/app/controllers/unattended_controller.rb:218:in

`safe_render’

/usr/share/foreman/app/controllers/unattended_controller.rb:74:in

`render_template’

/usr/share/foreman/app/controllers/unattended_controller.rb:47:in

`host_template’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_co
ntroller/metal/implicit_render.rb:4:in `send_action’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_
controller/base.rb:198:in `process_action’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/action_co
ntroller/metal/rendering.rb:10:in `process_action’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/actionpack-4.2.5.1/lib/abstract_
controller/callbacks.rb:20:in `block in process_action’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:117:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:117:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:555:in `block (2 levels) in compile’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:505:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:505:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:498:in `block (2 levels) in around’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:313:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:313:in `block (2 levels) in halting’

/usr/share/foreman/app/controllers/concerns/application_shared.rb:15:in

`set_timezone’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:432:in `block in make_lambda’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:312:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:312:in `block in halting’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:497:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:497:in `block in around’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:505:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:505:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:498:in `block (2 levels) in around’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:313:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:313:in `block (2 levels) in halting’

/usr/share/foreman/app/models/concerns/foreman/thread_session.rb:32:in

`clear_thread’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:432:in `block in make_lambda’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:312:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:312:in `block in halting’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:497:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:497:in `block in around’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:505:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:505:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:498:in `block (2 levels) in around’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:313:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:313:in `block (2 levels) in halting’

/usr/share/foreman/app/controllers/concerns/foreman/controller/topbar_sweepe
r.rb:12:in `set_topbar_sweeper_controller’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:432:in `block in make_lambda’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:312:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:312:in `block in halting’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:497:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:497:in `block in around’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:505:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:505:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:498:in `block (2 levels) in around’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:313:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:313:in `block (2 levels) in halting’

/opt/theforeman/tfm/root/usr/share/gems/gems/audited-4.4.1/lib/audited/sweep
er.rb:14:in `around’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:455:in `public_send’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:455:in `block in make_lambda’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:312:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:312:in `block in halting’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:497:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:497:in `block in around’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:505:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:505:in `call’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:92:in `run_callbacks

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:778:in `_run_process_action_callbacks’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/activesupport-4.2.5.1/lib/active
_support/callbacks.rb:81:in `run_callbacks’

/opt/rh/sclo-ror42/root/usr/share/gems/gems/action

>
> Hello,
>
> it looks like Feature #14664: Add IPv6 Subnet to Host, Hostgroup and Nic Models - Foreman which was fixed
> in
> 1.13, subnet6 is among allowed attributes. The error message might be
> misleading, double check the host interfaces. You can debug the snippet
> using
> the preview button when editing the template.
>
> –
> Marek
>

So I did run a preview on various hosts and it failed on all of them. The
output wasn't helpful other than to say it failed. Not why it failed. The
errors in the log look the similar as well.

2017-10-09 15:12:44 6d0e1450 [templates] [I] Rendering template
'kickstart_ifcfg_generic_interface'
2017-10-09 15:12:44 6d0e1450 [app] [W] Error rendering the
kickstart_ifcfg_generic_interface template
> Safemode::NoMethodError: undefined method '#ip6' for NilClass::Jail
(NilClass)
>
/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode/jail.rb:22:in
method_missing&#39; &gt; kickstart_ifcfg_generic_interface:71:inbind'

Also, you mentioned 1.13, we're running 1.15.1.

Here is the snippet we have currently.

<%#
name: kickstart_ifcfg_generic_interface
snippet: true
model: ProvisioningTemplate
kind: snippet
-%>
BOOTPROTO="<%= @dhcp ? 'dhcp' : 'none' -%>"
<%- unless @dhcp || @subnet.nil? -%>
<%- if @interface.ip.present? -%>
<%= "IPADDR=&quot;#{@interface.ip}&quot;" %>
<%= "NETMASK=&quot;#{@subnet.mask}&quot;" %>
<%- if @subnet.gateway.present? -%>
<%= "GATEWAY=&quot;#{@subnet.gateway}&quot;" %>
<%- end -%>
<%- end -%>
<%- end -%>
<%- if @interface.ip6.present? -%>
<%= "IPV6INIT=yes" %>
<%= "IPV6_AUTOCONF=no" %>
<%= "IPV6ADDR=#{@interface.ip6}" %>
<%- if !@subnet6.nil? && @subnet6.gateway.present? -%>
<%= "IPV6_DEFAULTGW=#{@subnet6.gateway}" %><%= '%$real' if
subnet6.gateway.match(/^fe80:/) %>
<%- end -%>
<%= "IPV6_PEERDNS=no" %>
<%- end -%>
DEVICE=$real
<%- unless @interface.virtual? -%>
<%= "HWADDR=&quot;#{@interface.mac}&quot;" %>
<%- end -%>
ONBOOT=yes
<%- primary = @interface.primary ? 'yes' : 'no' -%>
PEERDNS=<%= primary %>
PEERROUTES=<%= primary %>
DEFROUTE=<%= primary %>
<%- if @interface.primary -%>
<%- if !@dhcp && @subnet && @subnet.dns_primary.present? -%>
<%= "DNS1=&quot;#{@subnet.dns_primary}&quot;" %>
<%- if @subnet.dns_secondary.present? -%>
<%= "DNS2=&quot;#{@subnet.dns_secondary}&quot;" %>
<%- end -%>
<%- end -%>
<%- end -%>
<%- if @interface.virtual? && ((!@subnet.nil? && @subnet.has_vlanid?) ||
@interface.vlanid.present?) -%>
<%= "VLAN=yes" %>
<%- elsif @interface.virtual? && !@subnet.nil? && !@subnet.has_vlanid? &&
@interface.identifier.include?(':') -%>
<%= "TYPE=Alias" %>
<%- end -%>

··· On Monday, October 9, 2017 at 4:01:16 AM UTC-5, Marek Hulán wrote:

Hello

Based on the error message, it seems that @interface is nil for some reason.
OTOH I don't understand why it wouldn't fail on @interface.ip few lines above.

Sorry, no more ideas

··· -- Marek

On pondělí 9. října 2017 17:16:23 CEST Mike Wilson wrote:

On Monday, October 9, 2017 at 4:01:16 AM UTC-5, Marek Hulán wrote:

Hello,

it looks like Feature #14664: Add IPv6 Subnet to Host, Hostgroup and Nic Models - Foreman which was fixed
in
1.13, subnet6 is among allowed attributes. The error message might be
misleading, double check the host interfaces. You can debug the snippet
using
the preview button when editing the template.

So I did run a preview on various hosts and it failed on all of them. The
output wasn’t helpful other than to say it failed. Not why it failed. The
errors in the log look the similar as well.

2017-10-09 15:12:44 6d0e1450 [templates] [I] Rendering template
’kickstart_ifcfg_generic_interface’
2017-10-09 15:12:44 6d0e1450 [app] [W] Error rendering the
kickstart_ifcfg_generic_interface template

Safemode::NoMethodError: undefined method ‘#ip6’ for NilClass::Jail

(NilClass)

/opt/theforeman/tfm/root/usr/share/gems/gems/safemode-1.3.1/lib/safemode/jai
l.rb:22:in `method_missing’

kickstart_ifcfg_generic_interface:71:in `bind’

Also, you mentioned 1.13, we’re running 1.15.1.

Here is the snippet we have currently.

<%#
name: kickstart_ifcfg_generic_interface
snippet: true
model: ProvisioningTemplate
kind: snippet
-%>
BOOTPROTO="<%= @dhcp ? ‘dhcp’ : ‘none’ -%>"
<%- unless @dhcp || @subnet.nil? -%>
<%- if @interface.ip.present? -%>
<%= “IPADDR=”#{@interface.ip}"" %>
<%= “NETMASK=”#{@subnet.mask}"" %>
<%- if @subnet.gateway.present? -%>
<%= “GATEWAY=”#{@subnet.gateway}"" %>
<%- end -%>
<%- end -%>
<%- end -%>
<%- if @interface.ip6.present? -%>
<%= “IPV6INIT=yes” %>
<%= “IPV6_AUTOCONF=no” %>
<%= “IPV6ADDR=#{@interface.ip6}” %>
<%- if !@subnet6.nil? && @subnet6.gateway.present? -%>
<%= “IPV6_DEFAULTGW=#{@subnet6.gateway}” %><%= ‘%$real’ if
subnet6.gateway.match(/^fe80:/) %>
<%- end -%>
<%= “IPV6_PEERDNS=no” %>
<%- end -%>
DEVICE=$real
<%- unless @interface.virtual? -%>
<%= “HWADDR=”#{@interface.mac}"" %>
<%- end -%>
ONBOOT=yes
<%- primary = @interface.primary ? ‘yes’ : ‘no’ -%>
PEERDNS=<%= primary %>
PEERROUTES=<%= primary %>
DEFROUTE=<%= primary %>
<%- if @interface.primary -%>
<%- if !@dhcp && @subnet && @subnet.dns_primary.present? -%>
<%= “DNS1=”#{@subnet.dns_primary}"" %>
<%- if @subnet.dns_secondary.present? -%>
<%= “DNS2=”#{@subnet.dns_secondary}"" %>
<%- end -%>
<%- end -%>
<%- end -%>
<%- if @interface.virtual? && ((!@subnet.nil? && @subnet.has_vlanid?) ||
@interface.vlanid.present?) -%>
<%= “VLAN=yes” %>
<%- elsif @interface.virtual? && !@subnet.nil? && !@subnet.has_vlanid? &&
@interface.identifier.include?(’:’) -%>
<%= “TYPE=Alias” %>
<%- end -%>