Project

General

Profile

Actions

Bug #3149

closed

Facter 1.7.3 upgrade breaks fact timestamps in Foreman 1.2.2

Added by Ben McClure over 10 years ago. Updated over 10 years ago.

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

Description

Upgraded to facter-1.7.3-1ubuntu1 and Foreman stopped reporting the timestamp on facts that it received from my ENC script.

The timestamp in the YAML file for the node has changed its definition from:

!ruby/sym "_timestamp" 

to just:
"_timestamp" 

Thanks to ohadlevy on IRC I was able to correct this in my install by changing the following file:
/usr/share/foreman/app/models/host/base.rb

Line 67 now reads:

time = facts[:_timestamp] || facts['_timestamp']

This should support both the old and new way of defining _timestamp in the fact file. I can confirm this fixes the issue for me, and can submit a patch tomorrow for this if needed.

Thanks!

Actions

Also available in: Atom PDF