redhataccess / foreman-plugin

Container for Foreman Plugin
13 stars 20 forks source link

The plugin relies on /etc/redhat_access/config.yml #20

Open ares opened 6 years ago

ares commented 6 years ago

Other Foreman plugins use /etc/foreman/settings.d/redhat_access.yml, it might be good to unify this

ares commented 6 years ago

Also it would be good to provide better error message in case the file does not exist. Now it fails with

NameError: uninitialized constant RedhatAccess::Api::LogsController::REDHAT_ACCESS_CONFIG

and cryptic trace

lphiri commented 6 years ago

@ares are you seeing this error during build?

ares commented 6 years ago

yes

EDIT: which should be fixed easily by cp in %build but in geneneral, I was pretty confused by the same error when I installed devel setup. I think we should catch that exception or simply add a check and print nicer error message

lphiri commented 6 years ago

I have added a default config file that should help with the config build error: https://github.com/redhataccess/foreman-plugin/commit/e93891a50f6ce94149395ae0119058b93c8ab64d

Keeping the issue open to address moving the config to settings.d directory