Undefined method '==' for Safemode::Jail (Architecture) error

I can't seem to string match against the architecture macro. The code I'm
using (in my PXELinux template) is:

<% if @host.architecture == "x86_32" -%>
<% boot_params = "console=/dev/ttyACM0" -%>
<% end -%>

The error I get is:

There was an error rendering the Preseed default PXElinux template:
undefined method '==' for Safemode::Jail (Architecture)

AFAICT this should work. Am I wrong? If not, is there some way to
workaround? I just need a match against a literal.

try @host.arch.name == … ?

··· On Sun, Oct 6, 2013 at 1:26 PM, Jassi Singh wrote:

I can’t seem to string match against the architecture macro. The code I’m
using (in my PXELinux template) is:

<% if @host.architecture == “x86_32” -%>
<% boot_params = “console=/dev/ttyACM0” -%>
<% end -%>

The error I get is:

There was an error rendering the Preseed default PXElinux template:
undefined method ‘==’ for Safemode::Jail (Architecture)

AFAICT this should work. Am I wrong? If not, is there some way to
workaround? I just need a match against a literal.


You received this message because you are subscribed to the Google Groups
"Foreman users" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to foreman-users+unsubscribe@googlegroups.com.
To post to this group, send email to foreman-users@googlegroups.com.
Visit this group at http://groups.google.com/group/foreman-users.
For more options, visit https://groups.google.com/groups/opt_out.

>
> try @host.arch.name == … ?
>
>
Unfortunately doesn't work:
Error:

There was an error rendering the Preseed default PXElinux template: undefined method 'arch' for Host::Managed::Jail (Host::Managed)

··· On Sunday, October 6, 2013 11:55:32 AM UTC+1, ohad wrote:

On Sun, Oct 6, 2013 at 1:26 PM, Jassi Singh <jjsin...@googlemail.com<javascript:> > > wrote:

I can’t seem to string match against the architecture macro. The code
I’m using (in my PXELinux template) is:

<% if @host.architecture == “x86_32” -%>
<% boot_params = “console=/dev/ttyACM0” -%>
<% end -%>

The error I get is:

There was an error rendering the Preseed default PXElinux template:
undefined method ‘==’ for Safemode::Jail (Architecture)

AFAICT this should work. Am I wrong? If not, is there some way to
workaround? I just need a match against a literal.


You received this message because you are subscribed to the Google Groups
"Foreman users" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to foreman-user...@googlegroups.com <javascript:>.
To post to this group, send email to forema...@googlegroups.com<javascript:>
.
Visit this group at http://groups.google.com/group/foreman-users.
For more options, visit https://groups.google.com/groups/opt_out.

>
>
>>
>> try @host.arch.name == … ?
>>
>>
> Unfortunately doesn't work:
> Error:
>
> There was an error rendering the Preseed default PXElinux template: undefined method 'arch' for Host::Managed::Jail (Host::Managed)
>
>
>
yeah… I was cutting some corners… please use the full
@host.architecture.name

··· On Sun, Oct 6, 2013 at 3:26 PM, Jassi Singh wrote: > On Sunday, October 6, 2013 11:55:32 AM UTC+1, ohad wrote:

On Sun, Oct 6, 2013 at 1:26 PM, Jassi Singh jjsin...@googlemail.comwrote:

I can’t seem to string match against the architecture macro. The code
I’m using (in my PXELinux template) is:

<% if @host.architecture == “x86_32” -%>
<% boot_params = “console=/dev/ttyACM0” -%>
<% end -%>

The error I get is:

There was an error rendering the Preseed default PXElinux template:
undefined method ‘==’ for Safemode::Jail (Architecture)

AFAICT this should work. Am I wrong? If not, is there some way to
workaround? I just need a match against a literal.


You received this message because you are subscribed to the Google
Groups “Foreman users” group.
To unsubscribe from this group and stop receiving emails from it, send
an email to foreman-user…@googlegroups.com.
To post to this group, send email to forema...@googlegroups.com
.

Visit this group at http://groups.google.com/**group/foreman-usershttp://groups.google.com/group/foreman-users
.
For more options, visit https://groups.google.com/**groups/opt_outhttps://groups.google.com/groups/opt_out
.


You received this message because you are subscribed to the Google Groups
"Foreman users" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to foreman-users+unsubscribe@googlegroups.com.
To post to this group, send email to foreman-users@googlegroups.com.
Visit this group at http://groups.google.com/group/foreman-users.
For more options, visit https://groups.google.com/groups/opt_out.