Project

General

Profile

Actions

Bug #2017

closed

compute_attributes is nil on a machine injected via puppet agent

Added by David Swift over 11 years ago. Updated almost 7 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
Host creation
Target version:
-
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

I have a few EC2 instances that we created before we started using foreman. When I install puppet, and point it at my current Foreman/Puppet server, the instance makes contact, and runs a short puppet run. It is then available in the Foreman Hosts list.

When I Edit that machine, and attempt to assign it a hostgroup, when I hit Save, I get

undefined method `[]' for nil:NilClass

NoMethodError
undefined method `[]' for nil:NilClass
app/models/orchestration/compute.rb:185:in `validate_compute_provisioning'
app/models/orchestration.rb:64:in `valid?'
app/controllers/hosts_controller.rb:104:in `update'

tracking this down, I think I can fix the validation, so that if the compute_attributes are missing it creates reasonable defaults. Pull request coming (I am on the dev branch, mostly up-to-date)


Files

Screen_shot_2012-12-06_at_12.08.25_PM.png View Screen_shot_2012-12-06_at_12.08.25_PM.png 307 KB Screenshot of host edit screen. David Swift, 12/06/2012 03:11 PM
Actions

Also available in: Atom PDF