GithubHelp home page GithubHelp logo

theforeman / foreman_virt_who_configure Goto Github PK

View Code? Open in Web Editor NEW
5.0 7.0 24.0 1.03 MB

License: GNU General Public License v3.0

Ruby 9.91% HTML 2.14% Makefile 0.21% JavaScript 87.67% SCSS 0.07%
hacktoberfest

foreman_virt_who_configure's Introduction

Foreman Virt Who Configure

A Foreman plugin to make virt-who configuration easier. This provides a simple UI for obtaining required information about the desired virt-who configuration, such as hypervisor credentials, check interval and other similar config options. After the information is gathered, it provides a configuration script that can be used to install and configure the virt-who instance. All incoming reports from such virt-who instance are tracked and monitored by the plugin.

Installation

This plugins requires Katello to be installed in your Foreman instance. If it's there, simply install a package with the plugin (rpm only), run migrations and seed by running,

dnf install rubygem-foreman_virt_who_configure foreman-rake db:migrate foreman-rake db:seed

Usage

After installation there is new "Virt-who configurations" menu added in "Infrastructure" tab. The "Virt-who configurations" -> "Create Config" provides options to add details about configuration, most of the fields are having inline help.

The virt-who configuration should be in an organization. If an organization has not selected then Owner field would be displayed where it is required to select organization. If organization is already selected then Owner field is not displayed and virt-configuration will be automatically created in selected organization scope.

To deploy the configuration click on configuration name on "Virt-who configurations" list page, "Overview" page shows details about configuration and "Deploy page" has all details on deploying configuration.

More details are available at - https://theforeman.org/plugins/foreman_virt_who_configure

Contributing

Fork and send a Pull Request. Thanks!

Copyright

Copyright (c) 2023 - Foreman team

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

foreman_virt_who_configure's People

Contributors

ares avatar chris1984 avatar ekohl avatar jlsherrill avatar jpasqualetto avatar jturel avatar lfu avatar piyushtiw avatar pkliczewski avatar ranjan avatar sayan3296 avatar sbernhard avatar sthirugn avatar thulium-drake avatar upadhyeammit avatar wbclark avatar xprazak2 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

foreman_virt_who_configure's Issues

Small visual imperfections in config index page

  • Heading of the interval field is "Config|Interval" instead of just "Interval". It might be just due to missing translation, I'm not sure.
  • Interval values should be displayed in human readable form ('every 8 hours' vs 'every 480 minutes')

Script generated by plugin can't handle special characters in password

Hi there!

I recently configured virt-who on Satellite 6.10 and attempted to deploy the configuration generated by this plugin, but it seems that the script is not able to handle passwords with certain special characters in it.

In my case the password that was provided to us for logging in on the hypervisor had a ` in it, which breaks the shell escaping in the generated bash script.

cr_password=`virt-who-password --password $(echo #{cr_password_base64}|base64 -d) 2> /dev/null`

I was succesfully able to work around it by replacing the ` with $( )

Unable to connect to libvirt server using password, requires ssh key

# virt-who --one-shot --debug
2017-02-17 17:10:05,169 [virtwho.init WARNING] MainProcess(27378):MainThread @config.py:checkOptions:328 - Password authentication doesn't work with ssh transport on libvirt backend, copy your public ssh key to the remote machine
2017-02-17 17:10:05,169 [virtwho.init DEBUG] MainProcess(27378):MainThread @executor.py:__init__:66 - Using config named 'virt-who-config-2'
2017-02-17 17:10:05,169 [virtwho.init INFO] MainProcess(27378):MainThread @main.py:main:165 - Using configuration "virt-who-config-2" ("libvirt" mode)
2017-02-17 17:10:05,169 [virtwho.init INFO] MainProcess(27378):MainThread @main.py:main:167 - Using reporter_id='<hidden.-162c36e5653242ecaf1e49629c311950'
2017-02-17 17:10:05,204 [virtwho.virt-who-config-2 DEBUG] Libvirtd-1(27384):MainThread @virt.py:run:379 - Virt backend 'virt-who-config-2' started
2017-02-17 17:10:05,204 [virtwho.virt-who-config-2 INFO] Libvirtd-1(27384):MainThread @libvirtd.py:_get_url:125 - Protocol is not specified in libvirt url, using qemu+ssh://
2017-02-17 17:10:05,205 [virtwho.virt-who-config-2 INFO] Libvirtd-1(27384):MainThread @libvirtd.py:_get_url:136 - Libvirt path is not specified in the url, using /system
2017-02-17 17:10:05,205 [virtwho.virt-who-config-2 INFO] Libvirtd-1(27384):MainThread @libvirtd.py:_connect:157 - Using libvirt url: qemu+ssh://root@<hidden>/system?no_tty=1
2017-02-17 17:10:05,415 [virtwho.virt-who-config-2 ERROR] Libvirtd-1(27384):MainThread @libvirtd.py:_connect:165 - Error in libvirt backend
Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/virtwho/virt/libvirtd/libvirtd.py", line 161, in _connect
    v = libvirt.openAuth(url, auth, libvirt.VIR_CONNECT_RO)
  File "/usr/lib64/python2.7/site-packages/libvirt.py", line 105, in openAuth
    if ret is None:raise libvirtError('virConnectOpenAuth() failed')
libvirtError: Cannot recv data: Host key verification failed.: Connection reset by peer
2017-02-17 17:10:05,417 [virtwho.virt-who-config-2 ERROR] Libvirtd-1(27384):MainThread @virt.py:run:390 - Virt backend 'virt-who-config-2' fails with error: Cannot recv data: Host key verification failed.: Connection reset by peer
2017-02-17 17:10:05,417 [virtwho.virt-who-config-2 DEBUG] Libvirtd-1(27384):MainThread @virt.py:enqueue:372 - Report for config "virt-who-config-2" gathered, putting to queue for sending
2017-02-17 17:10:05,423 [virtwho.virt-who-config-2 DEBUG] Libvirtd-1(27384):MainThread @virt.py:run:400 - Virt backend 'virt-who-config-2' stopped after sending one report
2017-02-17 17:10:05,424 [virtwho.main WARNING] MainProcess(27378):MainThread @executor.py:run:252 - Unable to collect report for config "virt-who-config-2"
2017-02-17 17:10:05,425 [virtwho.main DEBUG] MainProcess(27378):MainThread @__main__.py:main:23 - virt-who terminated
2017-02-17 17:10:05,425 [virtwho.main DEBUG] MainProcess(27378):MainThread @executor.py:terminate:308 - virt-who is shutting down

Permission issue in Satellite after running `virt-who --one-shot` using libvirt

  • I was able to run virt-who --one-shot after applying the workaround for #17 but this results in an error in Satellite.
  • Note: I am using a separate server for virt-who here and not using Satellite server.
Access denied error in Satellite when running  `virt-who --one-shot` using libvirt


017-02-20 14:16:53 [katello/cp_proxy] [E] *** ERROR: Access denied (403) ***
2017-02-20 14:16:53 [katello/cp_proxy] [E] REQUEST URL: /rhsm/hypervisors?owner=Default+Organization&env=Library
2017-02-20 14:16:53 [katello/cp_proxy] [E] Katello::HttpErrors::Forbidden: Access denied
 | /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.95/app/controllers/katello/api/rhsm/candlepin_proxies_controller.rb:266:in `deny_access'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.95/app/controllers/katello/api/rhsm/candlepin_proxies_controller.rb:405:in `authorize_client_or_admin'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:424:in `block in make_lambda'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:143:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:143:in `block in halting_and_conditional'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.95/app/controllers/katello/api/rhsm/candlepin_proxies_controller.rb:27:in `repackage_message'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:424:in `block in make_lambda'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting'
 | /usr/share/foreman/app/controllers/api/v2/base_controller.rb:152:in `disable_json_root'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:424:in `block in make_lambda'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/rails-observers-0.1.2/lib/rails/observers/action_controller/caching/sweeping.rb:73:in `around'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:447:in `public_send'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:447:in `block in make_lambda'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting'
 | /usr/share/foreman/app/controllers/concerns/application_shared.rb:13:in `set_timezone'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:424:in `block in make_lambda'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting'
 | /usr/share/foreman/app/models/concerns/foreman/thread_session.rb:32:in `clear_thread'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:424:in `block in make_lambda'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:229:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:166:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:299:in `block (2 levels) in halting'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/rails-observers-0.1.2/lib/rails/observers/action_controller/caching/sweeping.rb:73:in `around'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:447:in `public_send'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:447:in `block in make_lambda'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:298:in `block in halting'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:149:in `block in halting_and_conditional'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:86:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:86:in `run_callbacks'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/abstract_controller/callbacks.rb:19:in `process_action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_controller/metal/rescue.rb:29:in `process_action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_controller/metal/instrumentation.rb:31:in `block in process_action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/notifications.rb:159:in `block in instrument'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/notifications.rb:159:in `instrument'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_controller/metal/instrumentation.rb:30:in `process_action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_controller/metal/params_wrapper.rb:250:in `process_action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activerecord-4.1.5/lib/active_record/railties/controller_runtime.rb:18:in `process_action'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/katello-3.0.0.95/app/controllers/katello/concerns/api/api_controller.rb:39:in `process_action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/abstract_controller/base.rb:136:in `process'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionview-4.1.5/lib/action_view/rendering.rb:30:in `process'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_controller/metal.rb:196:in `dispatch'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_controller/metal/rack_delegation.rb:13:in `dispatch'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_controller/metal.rb:232:in `block in action'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/routing/route_set.rb:80:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/routing/route_set.rb:80:in `dispatch'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/routing/route_set.rb:48:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:71:in `block in call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:59:in `each'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:59:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/routing/route_set.rb:676:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/railties-4.1.5/lib/rails/engine.rb:514:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/railties-4.1.5/lib/rails/railtie.rb:194:in `public_send'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/railties-4.1.5/lib/rails/railtie.rb:194:in `method_missing'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:71:in `block in call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:59:in `each'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/journey/router.rb:59:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/routing/route_set.rb:676:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.3.6/lib/apipie/static_dispatcher.rb:65:in `call'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.3.6/lib/apipie/extractor/recorder.rb:132:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/apipie-rails-0.3.6/lib/apipie/middleware/checksum_in_headers.rb:27:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/etag.rb:23:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/conditionalget.rb:35:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/head.rb:11:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/params_parser.rb:27:in `call'
 | /usr/share/foreman/lib/middleware/catch_json_parse_errors.rb:9:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/flash.rb:254:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/session/abstract/id.rb:225:in `context'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/session/abstract/id.rb:220:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/cookies.rb:560:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activerecord-4.1.5/lib/active_record/query_cache.rb:36:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activerecord-4.1.5/lib/active_record/connection_adapters/abstract/connection_pool.rb:621:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/callbacks.rb:29:in `block in call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/callbacks.rb:82:in `run_callbacks'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/callbacks.rb:27:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/remote_ip.rb:76:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/debug_exceptions.rb:17:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/railties-4.1.5/lib/rails/rack/logger.rb:38:in `call_app'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/railties-4.1.5/lib/rails/rack/logger.rb:22:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/request_id.rb:21:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/methodoverride.rb:21:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/runtime.rb:17:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/activesupport-4.1.5/lib/active_support/cache/strategy/local_cache_middleware.rb:26:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/actionpack-4.1.5/lib/action_dispatch/middleware/static.rb:64:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/sendfile.rb:112:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/railties-4.1.5/lib/rails/engine.rb:514:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/railties-4.1.5/lib/rails/application.rb:144:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/railties-4.1.5/lib/rails/railtie.rb:194:in `public_send'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/railties-4.1.5/lib/rails/railtie.rb:194:in `method_missing'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/builder.rb:138:in `call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/urlmap.rb:65:in `block in call'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/urlmap.rb:50:in `each'
 | /opt/rh/rh-ror41/root/usr/share/gems/gems/rack-1.5.2/lib/rack/urlmap.rb:50:in `call'
 | /usr/lib/ruby/gems/1.8/gems/passenger-4.0.18/lib/phusion_passenger/rack/thread_handler_extension.rb:77:in `process_request'
 | /usr/lib/ruby/gems/1.8/gems/passenger-4.0.18/lib/phusion_passenger/request_handler/thread_handler.rb:140:in `accept_and_process_next_request'
 | /usr/lib/ruby/gems/1.8/gems/passenger-4.0.18/lib/phusion_passenger/request_handler/thread_handler.rb:108:in `main_loop'
 | /usr/lib/ruby/gems/1.8/gems/passenger-4.0.18/lib/phusion_passenger/request_handler.rb:441:in `block (3 levels) in start_threads'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/logging-1.8.2/lib/logging/diagnostic_context.rb:323:in `call'
 | /opt/theforeman/tfm/root/usr/share/gems/gems/logging-1.8.2/lib/logging/diagnostic_context.rb:323:in `block in create_with_logging_context'
2017-02-20 14:16:53 [app] [I] Completed 500 Internal Server Error in 60ms
2017-02-20 14:16:53 [app] [F] 
 | AbstractController::DoubleRenderError (Render and/or redirect were called multiple times in this action. Please note that you may only call render OR redirect, and at most once per action. Also note that neither redirect nor render terminate execution of the action, so if you want to exit an action after redirecting, you need to do something like "redirect_to(...) and return".):
 |   katello (3.0.0.95) app/lib/katello/api/v2/error_handling.rb:126:in `block (2 levels) in respond_for_exception'
 |   katello (3.0.0.95) app/lib/katello/api/v2/error_handling.rb:124:in `respond_for_exception'
 |   katello (3.0.0.95) app/lib/katello/api/v2/error_handling.rb:52:in `rescue_from_wrapped_error'
 |   katello (3.0.0.95) app/controllers/katello/concerns/api/api_controller.rb:39:in `process_action'
 |   lib/middleware/catch_json_parse_errors.rb:9:in `call'
 | 
 | 

==> /var/log/httpd/foreman-ssl_access_ssl.log <==
10.19.34.51 - - [20/Feb/2017:14:16:53 -0500] "POST /rhsm/hypervisors?owner=Default+Organization&env=Library HTTP/1.1" 500 48 "-" "RHSM/1.0 (cmd=virt-who)"
https://bugzilla.redhat.com/show_bug.cgi?id=1258726
==> /var/log/foreman/production.log <==
2017-02-20 14:18:22 [app] [I] Started GET "/node/satellite.example.com?format=yml" for 192.168.1.1 at 2017-02-20 14:18:22 -0500
2017-02-20 14:18:22 [app] [I] Processing by HostsController#externalNodes as YML
2017-02-20 14:18:22 [app] [I]   Parameters: {"name"=>"satellite.example.com"}
2017-02-20 14:18:23 [app] [I]   Rendered text template (0.0ms)
2017-02-20 14:18:23 [app] [I] Completed 200 OK in 445ms (Views: 0.8ms | ActiveRecord: 40.6ms)

==> /var/log/httpd/foreman-ssl_access_ssl.log <==
192.168.1.1 - satellite.example.com [20/Feb/2017:14:18:22 -0500] "GET /node/satellite.example.com?format=yml HTTP/1.1" 200 2430 "-" "-"

==> /var/log/httpd/puppet_access_ssl.log <==
192.168.1.1 - - [20/Feb/2017:14:18:22 -0500] "GET /production/node/satellite.example.com?transaction_uuid=c915a5cf-9395-4af7-88cf-9f570c039648&fail_on_404=true HTTP/1.1" 200 8082 "-" "-"
192.168.1.1 - - [20/Feb/2017:14:18:23 -0500] "GET /production/file_metadatas/pluginfacts?checksum_type=md5&ignore=.svn&ignore=CVS&ignore=.git&links=manage&recurse=true HTTP/1.1" 200 283 "-" "-"
192.168.1.1 - - [20/Feb/2017:14:18:24 -0500] "GET /production/file_metadatas/plugins?checksum_type=md5&ignore=.svn&ignore=CVS&ignore=.git&links=manage&recurse=true HTTP/1.1" 200 36753 "-" "-"

==> /var/log/foreman/production.log <==
2017-02-20 14:18:26 [app] [I] Started POST "/api/hosts/facts" for 192.168.1.1 at 2017-02-20 14:18:26 -0500
2017-02-20 14:18:26 [app] [I] Processing by Api::V2::HostsController#facts as JSON
2017-02-20 14:18:26 [app] [I]   Parameters: {"name"=>"satellite.example.com", "facts"=>"[FILTERED]", "certname"=>"satellite.example.com", "apiv"=>"v2", :host=>{"name"=>"satellite.example.com", "certname"=>"satellite.example.com"}}
2017-02-20 14:18:26 [app] [I] Import facts for 'satellite.example.com' completed. Added: 0, Updated: 8, Deleted 0 facts
2017-02-20 14:18:27 [app] [I] Completed 201 Created in 484ms (Views: 11.7ms | ActiveRecord: 134.7ms)

==> /var/log/httpd/foreman-ssl_access_ssl.log <==
192.168.1.1 - satellite.example.com [20/Feb/2017:14:18:26 -0500] "POST /api/hosts/facts HTTP/1.1" 201 1028 "-" "-"

==> /var/log/foreman/production.log <==
2017-02-20 14:18:27 [app] [I] Started GET "/node/satellite.example.com?format=yml" for 192.168.1.1 at 2017-02-20 14:18:27 -0500
2017-02-20 14:18:27 [app] [I] Processing by HostsController#externalNodes as YML
2017-02-20 14:18:27 [app] [I]   Parameters: {"name"=>"satellite.example.com"}
2017-02-20 14:18:27 [app] [I]   Rendered text template (0.0ms)
2017-02-20 14:18:27 [app] [I] Completed 200 OK in 220ms (Views: 0.4ms | ActiveRecord: 10.5ms)

==> /var/log/httpd/foreman-ssl_access_ssl.log <==
192.168.1.1 - satellite.example.com [20/Feb/2017:14:18:27 -0500] "GET /node/satellite.example.com?format=yml HTTP/1.1" 200 2430 "-" "-"

Deploy script breaks when the password of hypervisor contains single quotes

When a user configures an account to communicate with a hypervisor and the password contains single quotes, the shell script for deploying virt-who configuration does not work.

Example: define the password to something like Tes't

The deployment script will be like this.

(...)

if verify_minimal_version; then
  step 2 "Encrypting password"
  cr_password=`virt-who-password --password 'Tes't' 2> /dev/null`

(...)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.