Project

General

Profile

Actions

Bug #10420

closed

Using Run Puppet button fails on Foreman 1.8.0

Added by Ryan Sabatini almost 9 years ago. Updated almost 6 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Puppet integration
Target version:
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

Clicking the Run Puppet button on a single host returns: ERF12-4252 [ProxyAPI::ProxyException]: Unable to execute Puppet run ([RestClient::InternalServerError]: 500 Internal Server Error)

This is because it is trying to execute the mcollective puppet run with no host in the "-I" option, and produced the following error in /var/log/foreman-proxy/proxy.log
D, [2015-05-07T04:20:46.563412 #21204] DEBUG -- : about to execute: /usr/bin/sudo u root /usr/bin/mco puppet runonce -I ''
W, [2015-05-07T04:21:28.061875 #21204] WARN - : Non-null exit code when executing '/usr/bin/sudo-uroot/usr/bin/mcopuppetrunonce-I'''
E, [2015-05-07T04:21:28.064903 #21204] ERROR -- : Failed puppet run: Check Log files
10.246.80.119 - - [07/May/2015 04:21:28] "POST /run HTTP/1.1" 500 34 41.5272

We were able to apply a patch to restore functionality to the Run Puppet button. The code change can be found below:
/app/models/host/managed.rb Line 567

#ProxyAPI::Puppet.new({:url => puppet_proxy.url}).run fqdn
ProxyAPI::Puppet.new({:url => puppet_proxy.url}).run facts["fqdn"]


Related issues 2 (0 open2 closed)

Related to Foreman - Bug #10403: Smart Class Parameter Overrides using the FQDN fact as a match no longer applies the overrideClosedDominic Cleal05/06/2015Actions
Related to Foreman - Bug #10307: Editing a host with "unattended: false" set in settings.yaml results in error.ClosedOndřej Pražák04/29/2015Actions
Actions

Also available in: Atom PDF