Bug #6402
closedUsing "run puppet" feature fails: undefined method `gsub' for #<Array ...>
Description
Warning! undefined method `gsub' for #<Array:0x00000008e13478> If you feel this is an error with Foreman itself, please open a new issue with Foreman ticketing system, You would probably need to attach the Full trace and relevant log entries. NoMethodError undefined method `gsub' for #<Array:0x00000008e13478> app/controllers/application_controller.rb:172:in `error' app/controllers/hosts_controller.rb:193:in `puppetrun' app/models/concerns/foreman/thread_session.rb:33:in `clear_thread' lib/middleware/catch_json_parse_errors.rb:9:in `call'
Log from client:
puppet-agent[6949]: Forbidden request: foreman(10.0.0.10) access to /run/client.fqdn [save] authenticated at :54
Updated by Jon Skarpeteig over 10 years ago
Should produce a proper error message instead of crashing
Updated by Dominic Cleal over 10 years ago
- Related to Bug #5881: CVE-2014-3491 - XSS from create/update/destroy notification boxes added
Updated by Dominic Cleal over 10 years ago
- Subject changed from Using "run puppet" feature fails to Using "run puppet" feature fails: undefined method `gsub' for #<Array ...>
- Category set to Puppet integration
Updated by Dominic Cleal over 10 years ago
- Has duplicate Bug #6429: Run Puppet causes Error 500 with message "Warning! undefined method `gsub' for #<Array:0x000000091b0608>" added
Updated by Brian Rak over 10 years ago
I also saw this when the foreman-proxy service was stopped, and I attempted to retrieve a certificate list.
Backtrace:
NoMethodError undefined method `gsub' for #<ActiveRecord::RecordNotFound: ActiveRecord::RecordNotFound> app/controllers/application_controller.rb:172:in `error' app/controllers/puppetca_controller.rb:17:in `rescue in index' app/controllers/puppetca_controller.rb:7:in `index' app/models/concerns/foreman/thread_session.rb:33:in `clear_thread' lib/middleware/catch_json_parse_errors.rb:9:in `call'
Updated by Roderick Day over 10 years ago
I was just seeing this same behavior with Foreman 1.5.1 and Puppet 3.6.2. Solved it by adding the following to my client's auth.conf (/etc/puppet/auth.conf)
- Allow puppet kick access
path /run
method save
auth any
allow *
"run puppet" feature now works a treat.
Updated by Roderick Day over 10 years ago
I should add that in the client log I saw the following:
Tue Jul 15 20:09:29 +0000 2014 Puppet (warning): Denying access: Forbidden request: puppet.example.com(<ip_address>) access to /run/hostname.example.com [save] authenticated at :119
Tue Jul 15 20:09:29 +0000 2014 Puppet (err): Forbidden request: puppet.example.com(<ip_address>) access to /run/hostname.example.com [save] authenticated at :119
Updated by Dominic Cleal over 10 years ago
- Status changed from New to Assigned
- Assignee set to Dominic Cleal
- Target version set to 1.8.0
Updated by The Foreman Bot over 10 years ago
- Status changed from Assigned to Ready For Testing
- Pull request https://github.com/theforeman/foreman/pull/1603 added
- Pull request deleted (
)
Updated by Dominic Cleal over 10 years ago
- Status changed from Ready For Testing to Closed
- % Done changed from 0 to 100
Applied in changeset b4fbdf574faf364fb1fc991c9363b3637ae70906.
Updated by Dominic Cleal over 10 years ago
- Has duplicate Bug #6351: <br /> seen in UI errors when multiple errors exist on a resource added
Updated by Dominic Cleal over 10 years ago
- Related to Bug #6903: "<br/>" in text when receiving error while deleting multiple hosts added
Updated by Dominic Cleal about 10 years ago
- Related to Bug #2383: Pushing the "Certificates" button on a smart proxy with disabled PuppetCA throws cryptic ActiveRecord error added