Open coolpalani opened 6 years ago
@coolpalani it works for me:
[root@cfme3 ~]# miqimport domain ServiceNow_Incident /tmp/ServiceNow_Incident/automate
DOMAIN_OPTIONS=overwrite=false;enabled=true;
[root@cfme3 ~]# rpm -q cfme
cfme-5.9.0.22-1.el7cf.x86_64
[root@cfme3 ~]#
Seems like something is funny with your appliance. Perhaps update related? What version of cfme are you on? How about ruby?
[root@cfme3 ~]# which ruby
/opt/rh/rh-ruby23/root/usr/bin/ruby
[root@cfme3 ~]# ruby -v
ruby 2.3.1p112 (2016-04-26 revision 54768) [x86_64-linux]
[root@cfme3 ~]#
Another alternative you might try is zipping up the domain from the level above the domain.yaml file and importing it through the UI.
-Jeff
I am also using the same appliance model.
[root@cmp ~]# rpm -q cfme
cfme-5.9.0.22-1.el7cf.x86_64
[root@cmp ~]# which ruby
/opt/rh/rh-ruby23/root/usr/bin/ruby
[root@cmp ~]# ruby -v
ruby 2.3.1p112 (2016-04-26 revision 54768) [x86_64-linux]
when I tried to import buttons this kind of error message is coming
[root@blrcmp ~]# miqimport buttons ServiceNow_Incident/buttons/ServiceNow_IM_Vm_.yaml Button Class: [Vm] Button Group: [ServiceNow_IM] Adding Button: Create Incident rake aborted! ActiveModel::MissingAttributeError: can't write unknown attribute
applies_to_exp /opt/rh/cfme-gemset/gems/activerecord-5.0.6/lib/active_record/attribute.rb:182:in
with_value_from_database'
/opt/rh/cfme-gemset/gems/activerecord-5.0.6/lib/active_record/attribute_set.rb:53:in write_from_user' /opt/rh/cfme-gemset/gems/activerecord-5.0.6/lib/active_record/attribute_methods/write.rb:50:in
write_attribute_with_type_cast'
/opt/rh/cfme-gemset/gems/activerecord-5.0.6/lib/active_record/attribute_methods/write.rb:32:in write_attribute' /opt/rh/cfme-gemset/gems/activerecord-5.0.6/lib/active_record/attribute_methods.rb:361:in
[]='
/var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake:146:in block in import_custom_buttons' /var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake:121:in
each'
/var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake:121:in import_custom_buttons' /var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake:184:in
block in import_custom_button_sets'
/var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake:172:in each' /var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake:172:in
import_custom_button_sets'
/var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake:63:in block in import_file' /opt/rh/cfme-gemset/gems/activerecord-5.0.6/lib/active_record/connection_adapters/abstract/database_statements.rb:232:in
block in transaction'
/opt/rh/cfme-gemset/gems/activerecord-5.0.6/lib/active_record/connection_adapters/abstract/transaction.rb:189:in within_new_transaction' /opt/rh/cfme-gemset/gems/activerecord-5.0.6/lib/active_record/connection_adapters/abstract/database_statements.rb:232:in
transaction'
/opt/rh/cfme-gemset/gems/activerecord-5.0.6/lib/active_record/transactions.rb:211:in transaction' /var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake:62:in
import_file'
/var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake:9:in import' /var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake:269:in
block (3 levels) in <top (required)>'
Tasks: TOP => rhconsulting:buttons:import
(See full trace by running task with --trace)`
@coolpalani - This is how we were able to resolve this, by commenting the following line (around 146).in: /var/www/miq/vmdb/lib/tasks/rhconsulting_buttons.rake
146 #custom_button['applies_to_exp'] = cb['applies_to_exp']
Thank you very much! It's working now :)
I am trying to import domain,alerts,button,service catalogues using /usr/bin/miqimport, but it's throwing an error message.
[root@cmp snow]# /usr/bin/miqimport domain ServiceNow_Incident ramrexx-ServiceNow_Incident-55a4b24/automate/ DOMAIN_OPTIONS=overwrite=false;enabled=true; Could not find psych-2.0.17 in any of the sources Run
bundle install
to install missing gems.I tried to execute bundle install also, it's still looking psych-2.0.17 package but system wide installed package version is psych-2.1.0.1-67.el7.x86_64
[root@cmp snow]# bundle install Don't run Bundler as root. Bundler can ask for sudo if it is needed, and installing your bundle as root will break this application for all non-root users on this machine. Fetching gem metadata from https://rubygems.org/........ Fetching version metadata from https://rubygems.org/... Fetching dependency metadata from https://rubygems.org/.. Fetching https://github.com/ManageIQ/manageiq-gems-pending.git Fetching https://github.com/ManageIQ/handsoap.git Fetching https://github.com/ManageIQ/amazon_ssa_support.git Fetching https://github.com/ManageIQ/foreman_api_client.git Fetching https://github.com/ManageIQ/jquery-rjs.git Fetching https://github.com/ManageIQ/manageiq-api Fetching https://github.com/ManageIQ/manageiq-automation_engine Fetching https://github.com/ManageIQ/manageiq-consumption Fetching https://github.com/ManageIQ/manageiq-content Fetching https://github.com/ManageIQ/manageiq-messaging Fetching https://github.com/ManageIQ/manageiq-providers-amazon Fetching https://github.com/ManageIQ/manageiq-providers-ansible_tower Fetching https://github.com/ManageIQ/manageiq-providers-azure Fetching https://github.com/ManageIQ/manageiq-providers-foreman Fetching https://github.com/ManageIQ/manageiq-providers-google Fetching https://github.com/ManageIQ/manageiq-providers-hawkular Fetching https://github.com/ManageIQ/manageiq-providers-kubernetes Fetching https://github.com/ManageIQ/manageiq-providers-lenovo Fetching https://github.com/ManageIQ/manageiq-providers-nuage Fetching https://github.com/ManageIQ/manageiq-providers-openshift Fetching https://github.com/ManageIQ/manageiq-providers-openstack Fetching https://github.com/ManageIQ/manageiq-providers-ovirt Fetching https://github.com/ManageIQ/manageiq-providers-scvmm Fetching https://github.com/ManageIQ/manageiq-providers-vmware Fetching https://github.com/ManageIQ/manageiq-schema Fetching https://github.com/ManageIQ/manageiq-ui-classic Your bundle is locked to redhat_access_cfme (2.0.2), but that version could not be found in any of the sources listed in your Gemfile. If you haven't changed sources, that means the author of redhat_access_cfme (2.0.2) has removed it. You'll need to update your bundle to a different version of redhat_access_cfme (2.0.2) that hasn't been removed in order to install.
Can I get any workaround to import this domain in CloudForms