Red Hat Satellite 6 backup fails with error: `expand_path': couldn't find HOME environment -- expanding `~' (ArgumentError) .

Solution Verified - Updated -

Issue

  • Runnig foreman-maintain backup using custom script fails with error:

    /usr/share/gems/gems/foreman_maintain-0.2.11/lib/foreman_maintain/config.rb:18:in `expand_path': couldn't find HOME environment -- expanding `~' (ArgumentError)
         from /usr/share/gems/gems/foreman_maintain-0.2.11/lib/foreman_maintain/config.rb:18:in `initialize'
         from /usr/share/gems/gems/foreman_maintain-0.2.11/lib/foreman_maintain.rb:54:in `new'
         from /usr/share/gems/gems/foreman_maintain-0.2.11/lib/foreman_maintain.rb:54:in `setup'
         from /usr/share/gems/gems/foreman_maintain-0.2.11/bin/foreman-maintain:12:in `<top (required)>'
         from /usr/bin/foreman-maintain:23:in `load'
         from /usr/bin/foreman-maintain:23:in `<main>'
    

Environment

  • Red Hat Satellite 6.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content