├── log └── .gitkeep ├── tmp └── .gitkeep ├── VERSION ├── bundler.d └── .gitkeep ├── lib ├── tasks │ └── .gitkeep ├── assets │ └── .gitkeep ├── active_metrics.rb ├── generators │ └── provider │ │ ├── templates │ │ ├── .rubocop_local.yml │ │ ├── lib │ │ │ ├── manageiq │ │ │ │ └── providers │ │ │ │ │ ├── %provider_name%.rb │ │ │ │ │ └── %provider_name% │ │ │ │ │ ├── version.rb │ │ │ │ │ └── engine.rb │ │ │ ├── manageiq-providers-%provider_name%.rb │ │ │ └── tasks │ │ │ │ ├── README.md │ │ │ │ └── %provider_name%.rake │ │ ├── .rspec │ │ ├── .rubocop_cc.yml │ │ ├── app │ │ │ └── models │ │ │ │ └── manageiq │ │ │ │ └── providers │ │ │ │ └── cloud_manager.rb │ │ ├── .rspec_ci │ │ ├── config │ │ │ ├── initializers │ │ │ │ └── gettext.rb │ │ │ └── settings.yml │ │ ├── .rubocop.yml │ │ └── .gitignore │ │ └── USAGE ├── miq_apache.rb ├── vmdb_extensions.rb ├── resource_feeder │ ├── lib │ │ └── resource_feeder.rb │ └── README ├── workers │ └── bin │ │ └── evm_server.rb ├── extensions │ ├── ar_adapter.rb │ ├── ar_column_names.rb │ ├── ar_number_of.rb │ ├── ar_paginate.rb │ ├── ar_base_model.rb │ ├── ar_href_slug.rb │ ├── ar_types.rb │ └── ar_base.rb ├── pdf_generator │ └── null_pdf_generator.rb ├── content_exporter.rb └── vmdb │ └── permission_stores │ └── null.rb ├── .dockerignore ├── app ├── mailers │ └── .gitkeep ├── models │ ├── .gitkeep │ ├── vm_server.rb │ ├── git_tag.rb │ ├── datacenter.rb │ ├── git_branch.rb │ ├── custom_event.rb │ ├── request_event.rb │ ├── git_reference.rb │ ├── storage_cluster.rb │ ├── auth_private_key.rb │ ├── dialog_field_button.rb │ ├── aliases │ │ ├── ems_cloud.rb │ │ ├── ems_infra.rb │ │ ├── vm_cloud.rb │ │ ├── vm_infra.rb │ │ ├── ems_network.rb │ │ ├── ems_middleware.rb │ │ ├── template_cloud.rb │ │ ├── ems_physical_infra.rb │ │ ├── miq_event_catcher.rb │ │ ├── miq_provision_cloud.rb │ │ ├── miq_ems_refresh_worker.rb │ │ ├── workers │ │ │ ├── ems_refresh_worker.rb │ │ │ └── event_catcher.rb │ │ ├── miq_provision_cloud_workflow.rb │ │ ├── miq_provision_infra_workflow.rb │ │ ├── miq_ems_metrics_collector_worker.rb │ │ ├── ems_refresh │ │ │ └── refreshers │ │ │ │ └── base_refresher.rb │ │ └── template_infra.rb │ ├── authentication_rhsm.rb │ ├── authentication_github.rb │ ├── authentication_google.rb │ ├── authentication_open_id.rb │ ├── configuration_domain.rb │ ├── configuration_realm.rb │ ├── authentication_allow_all.rb │ ├── authentication_htpasswd.rb │ ├── condition_set.rb │ ├── configuration_architecture.rb │ ├── configuration_environment.rb │ ├── container_volume_kubernetes.rb │ ├── miq_action_set.rb │ ├── scan_item_set.rb │ ├── template_xen.rb │ ├── authentication_request_header.rb │ ├── configuration_compute_profile.rb │ ├── customization_script_medium.rb │ ├── customization_script_ptable.rb │ ├── ems_refresh │ │ └── parsers │ │ │ └── infra.rb │ ├── vm_xen.rb │ ├── container_env_var.rb │ ├── miq_priority_worker │ │ └── runner.rb │ ├── miq_scsi_lun.rb │ ├── miq_reporting_worker │ │ └── runner.rb │ ├── container_groups_container_services.rb │ ├── host_switch.rb │ ├── scan_result.rb │ ├── container_limit_item.rb │ ├── host_storage.rb │ ├── openscap_rule_result.rb │ ├── ldap_group.rb │ ├── miq_ui_worker │ │ └── runner.rb │ ├── security_context.rb │ ├── miq_ems_metrics_processor_worker │ │ └── runner.rb │ ├── miq_report_result_detail.rb │ ├── tagging.rb │ ├── middleware_diagnostic_report.rb │ ├── cloud_tenant_flavor.rb │ ├── container_condition.rb │ ├── container_service_port_config.rb │ ├── host_aggregate_host.rb │ ├── miq_web_service_worker │ │ └── runner.rb │ ├── miq_widget_shortcut.rb │ ├── container_port_config.rb │ ├── dialog_yaml_serializer.rb │ ├── manageiq │ │ └── providers │ │ │ ├── automation_manager │ │ │ ├── authentication.rb │ │ │ ├── configured_system.rb │ │ │ ├── orchestration_stack.rb │ │ │ ├── configuration_script.rb │ │ │ ├── configuration_script_source.rb │ │ │ └── configuration_script_payload.rb │ │ │ ├── container_manager │ │ │ └── container_template.rb │ │ │ ├── physical_infra_manager │ │ │ └── refresh_parser.rb │ │ │ ├── embedded_automation_manager │ │ │ ├── inventory_group.rb │ │ │ ├── authentication.rb │ │ │ ├── configured_system.rb │ │ │ ├── inventory_root_group.rb │ │ │ ├── orchestration_stack.rb │ │ │ ├── configuration_script.rb │ │ │ ├── configuration_script_payload.rb │ │ │ └── configuration_script_source.rb │ │ │ ├── external_automation_manager │ │ │ ├── inventory_group.rb │ │ │ ├── authentication.rb │ │ │ ├── configured_system.rb │ │ │ ├── inventory_root_group.rb │ │ │ ├── orchestration_stack.rb │ │ │ ├── configuration_script.rb │ │ │ ├── configuration_script_payload.rb │ │ │ └── configuration_script_source.rb │ │ │ ├── storage_manager │ │ │ ├── cinder_manager │ │ │ │ └── refresh_worker │ │ │ │ │ └── runner.rb │ │ │ └── swift_manager │ │ │ │ └── refresh_worker │ │ │ │ └── runner.rb │ │ │ ├── embedded_ansible │ │ │ ├── automation_manager │ │ │ │ ├── event_catcher.rb │ │ │ │ ├── refresh_worker │ │ │ │ │ └── runner.rb │ │ │ │ ├── cloud_credential.rb │ │ │ │ ├── job │ │ │ │ │ └── status.rb │ │ │ │ ├── event_parser.rb │ │ │ │ ├── scm_credential.rb │ │ │ │ ├── amazon_credential.rb │ │ │ │ ├── google_credential.rb │ │ │ │ ├── network_credential.rb │ │ │ │ ├── vmware_credential.rb │ │ │ │ ├── machine_credential.rb │ │ │ │ ├── refresher.rb │ │ │ │ ├── openstack_credential.rb │ │ │ │ ├── rackspace_credential.rb │ │ │ │ ├── satellite6_credential.rb │ │ │ │ └── azure_classic_credential.rb │ │ │ └── inventory │ │ │ │ ├── parser │ │ │ │ ├── automation_manager.rb │ │ │ │ └── configuration_script_source.rb │ │ │ │ ├── collector │ │ │ │ ├── automation_manager.rb │ │ │ │ └── configuration_script_source.rb │ │ │ │ └── persister │ │ │ │ ├── automation_manager.rb │ │ │ │ └── configuration_script_source.rb │ │ │ ├── base_manager │ │ │ ├── metrics_capture.rb │ │ │ └── metrics_collector_worker │ │ │ │ └── runner.rb │ │ │ ├── middleware_manager.rb │ │ │ ├── datawarehouse_manager.rb │ │ │ └── cloud_manager │ │ │ └── provision │ │ │ └── configuration.rb │ ├── miq_widget_content.rb │ ├── storage_profile_storage.rb │ ├── subnet.rb │ ├── configuration_script.rb │ ├── ldap_management.rb │ ├── file_depot_ftp_anonymous.rb │ ├── miq_product_features_share.rb │ ├── orchestration_stack_resource.rb │ ├── auth_token.rb │ ├── orchestration_stack_parameter.rb │ ├── policy_event_content.rb │ ├── dialog_field_text_area_box.rb │ ├── load_balancer_listener_pool.rb │ ├── middleware_datasource_performance.rb │ ├── middleware_server_performance.rb │ ├── authentication_orchestration_stack.rb │ ├── load_balancer_pool_member_pool.rb │ ├── miq_queue_worker_base.rb │ ├── miq_smart_proxy_worker │ │ └── runner.rb │ ├── file_depot_nfs.rb │ ├── miq_scsi_target.rb │ ├── orchestration_template │ │ ├── orchestration_parameter_boolean.rb │ │ ├── orchestration_parameter_multiline.rb │ │ ├── orchestration_parameter_pattern.rb │ │ ├── orchestration_parameter_custom.rb │ │ ├── orchestration_parameter_allowed_dynamic.rb │ │ ├── orchestration_parameter_range.rb │ │ ├── orchestration_parameter_length.rb │ │ ├── orchestration_parameter_allowed.rb │ │ ├── orchestration_resource.rb │ │ └── orchestration_parameter_constraint.rb │ ├── orchestration_stack_output.rb │ ├── asset_details.rb │ ├── authentication_configuration_script_base.rb │ ├── load_balancer_health_check_member.rb │ ├── miq_event_handler.rb │ ├── miq_generic_worker │ │ └── runner.rb │ ├── dialog_field_association.rb │ ├── iso_image.rb │ ├── host_service_group.rb │ ├── windows_image.rb │ ├── cloud_subnet_network_port.rb │ ├── firmware.rb │ ├── miq_reporting_worker.rb │ ├── physical_server │ │ └── operations.rb │ ├── category.rb │ ├── miq_smart_proxy_worker.rb │ ├── miq_host_provision │ │ ├── post_install_callback.rb │ │ └── tagging.rb │ ├── network_port_security_group.rb │ ├── storage_performance.rb │ ├── configuration_script_payload.rb │ ├── customization_template_cloud_init.rb │ ├── miq_provision │ │ ├── helper.rb │ │ ├── description.rb │ │ ├── iso.rb │ │ └── genealogy.rb │ ├── computer_system.rb │ ├── ems_cluster_performance.rb │ ├── container_limit.rb │ ├── container_quota.rb │ ├── container_volume.rb │ ├── miq_priority_worker.rb │ ├── settings_change.rb │ ├── vm_or_template │ │ ├── operations │ │ │ └── smart_state.rb │ │ └── retirement_management.rb │ ├── vmdb_database_metric.rb │ ├── authentication_ldap.rb │ ├── manager_refresh │ │ └── inventory │ │ │ └── parser.rb │ ├── miq_report │ │ ├── formatters │ │ │ ├── html.rb │ │ │ ├── timeline.rb │ │ │ └── text.rb │ │ └── formatters.rb │ ├── compute_node.rb │ ├── container_performance.rb │ ├── scan_history.rb │ ├── serializer.rb │ ├── ext_management_system_performance.rb │ ├── container_node_performance.rb │ ├── host_performance.rb │ ├── container_group_performance.rb │ ├── container_template_parameter.rb │ ├── auth_userid_password.rb │ ├── container_project_performance.rb │ ├── metric.rb │ ├── miq_generic_worker.rb │ ├── miq_provision_task │ │ └── tagging.rb │ ├── rss_feed │ │ └── import_export.rb │ ├── host_metric.rb │ ├── resource_group.rb │ ├── cloud_object_store_object │ │ └── operations.rb │ ├── customization_script.rb │ ├── middleware_domain.rb │ ├── miq_web_service_worker.rb │ ├── configuration_script_source.rb │ ├── compliance_detail.rb │ ├── service_template_catalog.rb │ ├── mixins │ │ ├── cockpit_mixin.rb │ │ └── serialized_ems_ref_obj_mixin.rb │ ├── customization_spec.rb │ ├── miq_ems_metrics_processor_worker.rb │ └── miq_schedule_worker.rb └── channels │ ├── application_cable │ └── channel.rb │ └── notification_channel.rb ├── product ├── media │ └── .gitkeep ├── charts │ └── layouts │ │ ├── daily_perf_charts │ │ └── Container.yaml │ │ ├── hourly_perf_charts │ │ └── Container.yaml │ │ └── realtime_perf_charts │ │ └── Container.yaml └── scan_items │ ├── scan_item_cat.yaml │ └── scan_item_host_event.yaml ├── config ├── settings │ ├── production.yml │ ├── test.yml │ └── development.yml ├── brakeman.yml ├── ha_admin.yml ├── human_locale_names.yaml ├── cable.yml.sample ├── environment.rb ├── preinitializer.rb ├── initializers │ ├── nokogiri_as_xmlmini_backend.rb │ ├── mime_types.rb │ ├── session_patch.rb │ ├── active_metrics.rb │ └── yaml_autoloader.rb └── routes.rb ├── db └── fixtures │ ├── ae_datastore │ └── .gitkeep │ ├── arbitration_settings.yml │ ├── miq_alert_default_action.yml │ ├── users.yml │ ├── pxe_image_types.yml │ └── tools │ └── create_pxe_image_types_fixture.rb ├── spec ├── fixtures │ ├── files │ │ ├── import_widgets.yml │ │ ├── upload_image.txt │ │ ├── dialogs │ │ │ ├── seed_test.yaml │ │ │ ├── seed_test.yml │ │ │ ├── service_dialog_symlink │ │ │ ├── service_dialogs │ │ │ │ ├── service_seed_test.yaml │ │ │ │ └── service_seed_test.yml │ │ │ └── subdirectory │ │ │ │ ├── subdirectory_seed_test.yaml │ │ │ │ └── subdirectory_seed_test.yml │ │ ├── import_automate.yml │ │ ├── import_policies.yml │ │ ├── import_service_dialog.yml │ │ ├── dummy_file.yml │ │ └── upload_image.png │ └── git_repos │ │ └── branch_and_tag.git │ │ ├── refs │ │ ├── .gitkeep │ │ └── tags │ │ │ ├── tag1 │ │ │ └── tag2 │ │ ├── HEAD │ │ ├── config │ │ ├── objects │ │ ├── 43 │ │ │ └── 0ff1dcee43d2e8a12c3ba36f5ff20e46136152 │ │ ├── 44 │ │ │ └── f84e202a8eb9d8d35fc183ae8637db3b003aa8 │ │ ├── 78 │ │ │ └── 3878cb3ed5964c75767141176c80f7d528abb5 │ │ ├── 95 │ │ │ └── 99fdeb034597d90d72d2f58396dee096885b79 │ │ ├── ae │ │ │ └── fde3a01f6e10d72fd4899ce14c8b2654d3eb45 │ │ ├── e3 │ │ │ └── 16f7d7548ea8f874c872ff3be04f4e9849833b │ │ ├── e6 │ │ │ └── 9de29bb2d1d6434b8b29ae775ad8c2e48c5391 │ │ └── fd │ │ │ └── b4bc8c22f4b3ca8279c2e1eb92670893473d05 │ │ └── packed-refs ├── models │ ├── test_namespace_export1.xml │ ├── cloud_volume_snapshot_spec.rb │ ├── share_spec.rb │ ├── miq_product_features_share_spec.rb │ ├── configuration_location_spec.rb │ ├── miq_report │ │ └── seeding_spec.rb │ ├── configuration_organization_spec.rb │ ├── manageiq │ │ └── providers │ │ │ └── embedded_ansible │ │ │ ├── automation_manager_spec.rb │ │ │ └── automation_manager │ │ │ ├── job │ │ │ └── status_spec.rb │ │ │ └── configuration_script_source_spec.rb │ ├── customization_template_cloud_init_spec.rb │ ├── rss_feed │ │ └── import_export_spec.rb │ ├── pxe_data │ │ ├── ipxe │ │ │ └── mac │ │ │ │ └── 00-50-56-91-79-d5 │ │ └── pxelinux.cfg │ │ │ └── C0A8FDC7 │ ├── file_depot_ftp_anonymous_spec.rb │ ├── vmdb_metric_spec.rb │ ├── miq_policy_content_spec.rb │ ├── cloud_volume_spec.rb │ ├── factory_girl_spec.rb │ ├── container_image_registry_spec.rb │ └── miq_ae_class │ │ └── data │ │ ├── domain1 │ │ └── DOMAIN1 │ │ │ └── SYSTEM │ │ │ └── PROCESS.class │ │ │ ├── inst1.yaml │ │ │ ├── inst2.yaml │ │ │ ├── inst3.yaml │ │ │ └── inst4.yaml │ │ ├── domain2 │ │ └── DOMAIN2 │ │ │ └── SYSTEM │ │ │ └── PROCESS.class │ │ │ ├── inst1.yaml │ │ │ ├── inst2.yaml │ │ │ ├── inst31.yaml │ │ │ └── inst41.yaml │ │ └── domain3 │ │ └── DOMAIN3 │ │ └── SYSTEM │ │ └── PROCESS.class │ │ ├── inst1.yaml │ │ ├── inst2.yaml │ │ ├── inst32.yaml │ │ └── inst4.yaml ├── factories │ ├── job.rb │ ├── patch.rb │ ├── share.rb │ ├── session.rb │ ├── subnet.rb │ ├── tagging.rb │ ├── vm_scan.rb │ ├── volume.rb │ ├── auth_token.rb │ ├── chargeback.rb │ ├── dictionary.rb │ ├── event_log.rb │ ├── metering.rb │ ├── miq_filter.rb │ ├── miq_snmp.rb │ ├── os_process.rb │ ├── serializer.rb │ ├── vm_metric.rb │ ├── audit_event.rb │ ├── compute_node.rb │ ├── custom_event.rb │ ├── disk.rb │ ├── ems_refresh.rb │ ├── event_stream.rb │ ├── host_metric.rb │ ├── host_storage.rb │ ├── host_switch.rb │ ├── live_metric.rb │ ├── metering_vm.rb │ ├── miq_automate.rb │ ├── miq_shortcut.rb │ ├── scan_history.rb │ ├── scan_result.rb │ ├── switch.rb │ ├── sysprep_file.rb │ ├── authenticator.rb │ ├── chargeback_vm.rb │ ├── cloud_database.rb │ ├── condition_set.rb │ ├── container_build.rb │ ├── container_limit.rb │ ├── container_quota.rb │ ├── file_depot_nfs.rb │ ├── file_depot_smb.rb │ ├── firmware.rb │ ├── ldap_management.rb │ ├── lifecycle_event.rb │ ├── miq_action_set.rb │ ├── miq_bulk_import.rb │ ├── miq_reportable.rb │ ├── miq_user_scope.rb │ ├── network_group.rb │ ├── pxe_menu.rb │ ├── request_event.rb │ ├── service_generic.rb │ ├── advanced_setting.rb │ ├── asset_tag_import.rb │ ├── auth_private_key.rb │ ├── binary_blob.rb │ ├── configuration_tag.rb │ ├── container_env_var.rb │ ├── dialog_serializer.rb │ ├── drift_state.rb │ ├── host_performance.rb │ ├── iso_image.rb │ ├── ldap_domain.rb │ ├── ldap_group.rb │ ├── ldap_server.rb │ ├── ldap_user.rb │ ├── miq_ae_workspace.rb │ ├── miq_event_handler.rb │ ├── miq_region_remote.rb │ ├── partition.rb │ ├── schema_migration.rb │ ├── security_context.rb │ ├── vmdb_index.rb │ ├── application_record.rb │ ├── asset_details.rb │ ├── auth_userid_password.rb │ ├── authentication_rhsm.rb │ ├── cloud_resource_quota.rb │ ├── configuration_architecture.rb │ ├── configuration_domain.rb │ ├── configuration_realm.rb │ ├── container_build_pod.rb │ ├── container_condition.rb │ ├── container_limit_item.rb │ ├── container_quota_item.rb │ ├── firewall_rule.rb │ ├── host_aggregate_host.rb │ ├── iso_datastore.rb │ ├── job_proxy_dispatcher.rb │ ├── miq_ae_field.rb │ ├── miq_ae_value.rb │ ├── miq_approval.rb │ ├── miq_priority_worker.rb │ ├── miq_reporting_worker.rb │ ├── miq_widget_shortcut.rb │ ├── policy_event.rb │ ├── policy_event_content.rb │ ├── pxe_menu_ipxe.rb │ ├── registration_system.rb │ ├── registry_item.rb │ ├── retirement_manager.rb │ ├── scanning_operations.rb │ ├── storage_performance.rb │ ├── vim_performance_tag.rb │ ├── vm_migrate_workflow.rb │ ├── vm_reconfigure_task.rb │ ├── vmdb_database.rb │ ├── vmdb_database_lock.rb │ ├── binary_blob_part.rb │ ├── classification_import.rb │ ├── cloud_database_flavor.rb │ ├── computer_system.rb │ ├── container_performance.rb │ ├── container_port_config.rb │ ├── dialog_field_check_box.rb │ ├── dialog_field_importer.rb │ ├── dialog_tab_serializer.rb │ ├── dialog_yaml_serializer.rb │ ├── middleware_performance.rb │ ├── miq_alert_status.rb │ ├── miq_cockpit_ws_worker.rb │ ├── miq_queue_worker_base.rb │ ├── miq_smart_proxy_worker.rb │ ├── miq_web_service_worker.rb │ ├── notification_recipient.rb │ ├── operating_system.rb │ ├── pglogical_subscription.rb │ ├── pxe_image_type.rb │ ├── resource_action.rb │ ├── service_resource.rb │ ├── settings_change.rb │ ├── storage_profile.rb │ ├── vim_performance_daily.rb │ ├── vim_performance_trend.rb │ ├── vmdb_database_setting.rb │ ├── cloud_subnet_network_port.rb │ ├── configuration_environment.rb │ ├── container_template.rb │ ├── dialog_field_association.rb │ ├── dialog_field_date_control.rb │ ├── dialog_field_radio_button.rb │ ├── dialog_field_serializer.rb │ ├── dialog_group_serializer.rb │ ├── dialog_import_validator.rb │ ├── ems_cluster_performance.rb │ ├── file_depot_ftp_anonymous.rb │ ├── guest_application.rb │ ├── import_file_upload.rb │ ├── metering_container_image.rb │ ├── miq_event_definition_set.rb │ ├── miq_policy_content.rb │ ├── miq_report_result_detail.rb │ ├── miq_widget_content.rb │ ├── pxe_menu_pxelinux.rb │ ├── resource_action_workflow.rb │ ├── service_template_generic.rb │ ├── storage_profile_storage.rb │ ├── vim_performance_analysis.rb │ ├── vim_performance_planning.rb │ ├── vim_performance_tag_daily.rb │ ├── vim_performance_tag_value.rb │ ├── vm_cloud_reconfigure_task.rb │ ├── vmdb_database_connection.rb │ ├── widget_import_validator.rb │ ├── chargeback_container_image.rb │ ├── container_group_performance.rb │ ├── container_node_performance.rb │ ├── container_volume_kubernetes.rb │ ├── customization_script.rb │ ├── customization_script_medium.rb │ ├── customization_script_ptable.rb │ ├── dialog_field_text_area_box.rb │ ├── ems_event.rb │ ├── metering_container_project.rb │ ├── miq_event.rb │ ├── miq_host_provision_workflow.rb │ ├── miq_product_features_share.rb │ ├── miq_vim_broker_worker.rb │ ├── network_port_security_group.rb │ ├── resource_action_serializer.rb │ ├── vmdb_database_metric.rb │ ├── chargeback_container_project.rb │ ├── configuration_compute_profile.rb │ ├── container_project_performance.rb │ ├── container_service_port_config.rb │ ├── dialog_field_date_time_control.rb │ ├── middleware_diagnostic_report.rb │ ├── middleware_server_performance.rb │ ├── operating_system_flavor.rb │ ├── orchestration_stack_parameter.rb │ ├── service_template_ansible_tower.rb │ ├── vm_cloud_reconfigure_request.rb │ ├── notification.rb │ ├── vim_performance_operating_range.rb │ ├── authentication_orchestration_stack.rb │ ├── blacklisted_event.rb │ ├── container_groups_container_services.rb │ ├── container_template_parameter.rb │ ├── dialog_field_association_validator.rb │ ├── ext_management_system_performance.rb │ ├── load_balancer_listener_pool.rb │ ├── middleware_datasource_performance.rb │ ├── physical_server.rb │ ├── physical_server_provision_request.rb │ ├── physical_server_provision_workflow.rb │ ├── bottleneck_event.rb │ ├── dynamic_dialog_field_value_processor.rb │ ├── load_balancer_pool_member_pool.rb │ ├── miq_provision_request_template.rb │ ├── miq_queue.rb │ ├── miq_region.rb │ ├── authentication_configuration_script_base.rb │ ├── automate_workspace.rb │ ├── endpoint.rb │ ├── load_balancer_health_check_member.rb │ ├── miq_policy_set.rb │ ├── miq_provision_configured_system_request.rb │ ├── miq_provision_configured_system_workflow.rb │ ├── network.rb │ ├── server_role.rb │ ├── vm_performance.rb │ ├── automation_request.rb │ ├── container_deployment.rb │ ├── lan.rb │ ├── cloud_tenant_flavor.rb │ ├── miq_ems_refresh_core_worker.rb │ ├── container_deployment_node.rb │ ├── database_backup.rb │ ├── file_depot.rb │ ├── rss_feed.rb │ ├── resource_pool.rb │ ├── tag.rb │ ├── ldap_region.rb │ ├── miq_schedule_worker.rb │ ├── resource_groups.rb │ ├── auth_key_pair_cloud.rb │ ├── git_repositories.rb │ ├── snapshot.rb │ ├── generic_object.rb │ ├── miq_enterprise.rb │ ├── picture.rb │ ├── system_service.rb │ ├── auth_key_pair_amazon.rb │ ├── container_image.rb │ ├── container_routes.rb │ ├── container_volume.rb │ ├── log_file.rb │ ├── middleware_deployment.rb │ ├── miq_ae_namespace.rb │ ├── miq_compare.rb │ ├── zone.rb │ ├── auth_key_pair_openstack.rb │ ├── container_project.rb │ ├── container_services.rb │ ├── persistent_volume.rb │ ├── physical_infra_manager.rb │ ├── service_template_catalog.rb │ ├── host_service_group.rb │ ├── miq_template.rb │ ├── container_image_registry.rb │ ├── scan_item_set.rb │ ├── configuration_location.rb │ ├── template_google.rb │ ├── template_redhat.rb │ ├── persistent_volume_claim.rb │ ├── vim_performance_state.rb │ ├── vm_vmware_cloud.rb │ ├── configuration_organization.rb │ ├── miq_alert_status_action.rb │ ├── vmdb_metric.rb │ ├── vmware_refresh_worker.rb │ ├── storage_file.rb │ ├── template_microsoft.rb │ ├── cloud_object.rb │ ├── cloud_service.rb │ ├── miq_event_definition.rb │ ├── vm_redhat.rb │ ├── miq_scsi_lun.rb │ ├── miq_scsi_target.rb │ ├── chargeback_rate_detail_currency.rb │ ├── miq_database.rb │ ├── miq_widget_set.rb │ ├── pxe_server.rb │ ├── template_vmware_cloud.rb │ ├── categories.rb │ ├── windows_image.rb │ ├── service_order.rb │ ├── system_console.rb │ ├── template_azure.rb │ ├── miq_widget.rb │ ├── host_service_group_openstack.rb │ ├── miq_action.rb │ ├── miq_task.rb │ ├── vmdb_table.rb │ ├── notification_type.rb │ ├── vm_microsoft.rb │ ├── custom_attribute.rb │ ├── host_aggregate.rb │ ├── customization_spec_factory.rb │ ├── file_depot_ftp.rb │ └── vm_google.rb ├── rails_helper.rb ├── i18n │ └── placeholders_spec.rb ├── support │ ├── options_request.rb │ └── custom_matchers │ │ └── match_string_array_ignorecase.rb ├── shared │ └── README.md ├── lib │ ├── extensions │ │ └── ar_column_names_spec.rb │ └── vmdb │ │ └── fast_gettext_helper_spec.rb ├── initializers │ └── as_inflections_spec.rb └── database │ └── data │ └── id_column_whitelist.yml ├── .rspec ├── mime-types-redirector └── lib │ └── mime │ └── types.rb ├── tools ├── ci │ ├── setup_vmdb_configs.sh │ ├── setup_ruby_env.sh │ ├── after_failure.sh │ ├── setup_ruby_environment.rb │ ├── before_install.sh │ └── setup_vmdb_configs.rb ├── classify_vms_by_folder ├── purge_host_unknown_records.rb ├── pg_inspector │ └── error.rb ├── rest_api.rb ├── db_ping.rb ├── delete_ems_metadata_relationships.rb ├── miqldap_to_sssd │ └── sssd_conf │ │ └── pam.rb ├── delete_all_error_timeout_queue_messages.rb └── import_tags.rb ├── docker-assets └── check-dependent-services.sh ├── .rspec_ci ├── bin ├── rake ├── bundle ├── eslint └── rails ├── .rubocop_cc.yml ├── .yardopts ├── config.ru ├── certs └── v2_key.dev ├── .rubocop.yml ├── public ├── robots.txt └── proxy_pages │ └── invalid_sso_credentials.js ├── .yamllint └── locale ├── zh_CN.yml ├── es.yml └── fr.yml /log/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tmp/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /VERSION: -------------------------------------------------------------------------------- 1 | master 2 | -------------------------------------------------------------------------------- /bundler.d/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /lib/tasks/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.dockerignore: -------------------------------------------------------------------------------- 1 | .git 2 | -------------------------------------------------------------------------------- /app/mailers/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /app/models/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /lib/assets/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /product/media/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /config/settings/production.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /db/fixtures/ae_datastore/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/files/import_widgets.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/files/upload_image.txt: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/models/test_namespace_export1.xml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/files/dialogs/seed_test.yaml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/files/dialogs/seed_test.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/files/import_automate.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/files/import_policies.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/files/import_service_dialog.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /config/brakeman.yml: -------------------------------------------------------------------------------- 1 | --- 2 | :table_width: 400 3 | -------------------------------------------------------------------------------- /spec/fixtures/files/dummy_file.yml: -------------------------------------------------------------------------------- 1 | the yaml data 2 | -------------------------------------------------------------------------------- /app/models/vm_server.rb: -------------------------------------------------------------------------------- 1 | class VmServer < Vm 2 | end 3 | -------------------------------------------------------------------------------- /lib/active_metrics.rb: -------------------------------------------------------------------------------- 1 | require 'active_metrics/base' 2 | -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/refs/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /.rspec: -------------------------------------------------------------------------------- 1 | --require spec_helper 2 | --color 3 | --order random 4 | -------------------------------------------------------------------------------- /app/models/git_tag.rb: -------------------------------------------------------------------------------- 1 | class GitTag < GitReference 2 | end 3 | -------------------------------------------------------------------------------- /app/models/datacenter.rb: -------------------------------------------------------------------------------- 1 | class Datacenter < EmsFolder 2 | end 3 | -------------------------------------------------------------------------------- /app/models/git_branch.rb: -------------------------------------------------------------------------------- 1 | class GitBranch < GitReference 2 | end 3 | -------------------------------------------------------------------------------- /config/settings/test.yml: -------------------------------------------------------------------------------- 1 | :server: 2 | :session_store: memory 3 | -------------------------------------------------------------------------------- /mime-types-redirector/lib/mime/types.rb: -------------------------------------------------------------------------------- 1 | require 'mime-types' 2 | -------------------------------------------------------------------------------- /spec/fixtures/files/dialogs/service_dialog_symlink: -------------------------------------------------------------------------------- 1 | service_dialogs/ -------------------------------------------------------------------------------- /spec/fixtures/files/dialogs/service_dialogs/service_seed_test.yaml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/files/dialogs/service_dialogs/service_seed_test.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/files/dialogs/subdirectory/subdirectory_seed_test.yaml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /spec/fixtures/files/dialogs/subdirectory/subdirectory_seed_test.yml: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /tools/ci/setup_vmdb_configs.sh: -------------------------------------------------------------------------------- 1 | ./tools/ci/setup_vmdb_configs.rb 2 | -------------------------------------------------------------------------------- /app/models/custom_event.rb: -------------------------------------------------------------------------------- 1 | class CustomEvent < EventStream 2 | end 3 | -------------------------------------------------------------------------------- /app/models/request_event.rb: -------------------------------------------------------------------------------- 1 | class RequestEvent < EventStream 2 | end 3 | -------------------------------------------------------------------------------- /app/models/git_reference.rb: -------------------------------------------------------------------------------- 1 | class GitReference < ApplicationRecord 2 | end 3 | -------------------------------------------------------------------------------- /app/models/storage_cluster.rb: -------------------------------------------------------------------------------- 1 | class StorageCluster < EmsFolder 2 | end 3 | -------------------------------------------------------------------------------- /config/settings/development.yml: -------------------------------------------------------------------------------- 1 | --- 2 | :log: 3 | :level_rails: debug 4 | -------------------------------------------------------------------------------- /docker-assets/check-dependent-services.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | /bin/true 4 | -------------------------------------------------------------------------------- /spec/factories/job.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :job 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/patch.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :patch 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/share.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :share 3 | end 4 | -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/HEAD: -------------------------------------------------------------------------------- 1 | ref: refs/heads/branch2 2 | -------------------------------------------------------------------------------- /.rspec_ci: -------------------------------------------------------------------------------- 1 | --require spec_helper 2 | --color 3 | --order random 4 | --profile 25 5 | -------------------------------------------------------------------------------- /app/models/auth_private_key.rb: -------------------------------------------------------------------------------- 1 | class AuthPrivateKey < Authentication 2 | end 3 | -------------------------------------------------------------------------------- /app/models/dialog_field_button.rb: -------------------------------------------------------------------------------- 1 | class DialogFieldButton < DialogField 2 | end 3 | -------------------------------------------------------------------------------- /spec/factories/session.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :session 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/subnet.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :subnet 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/tagging.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :tagging 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vm_scan.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_scan 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/volume.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :volume 3 | end 4 | -------------------------------------------------------------------------------- /app/models/aliases/ems_cloud.rb: -------------------------------------------------------------------------------- 1 | ::EmsCloud = ::ManageIQ::Providers::CloudManager 2 | -------------------------------------------------------------------------------- /app/models/aliases/ems_infra.rb: -------------------------------------------------------------------------------- 1 | ::EmsInfra = ::ManageIQ::Providers::InfraManager 2 | -------------------------------------------------------------------------------- /app/models/aliases/vm_cloud.rb: -------------------------------------------------------------------------------- 1 | ::VmCloud = ManageIQ::Providers::CloudManager::Vm 2 | -------------------------------------------------------------------------------- /app/models/aliases/vm_infra.rb: -------------------------------------------------------------------------------- 1 | ::VmInfra = ManageIQ::Providers::InfraManager::Vm 2 | -------------------------------------------------------------------------------- /app/models/authentication_rhsm.rb: -------------------------------------------------------------------------------- 1 | class AuthenticationRhsm < Authentication 2 | end 3 | -------------------------------------------------------------------------------- /spec/factories/auth_token.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :auth_token 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/chargeback.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :chargeback 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dictionary.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dictionary 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/event_log.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :event_log 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/metering.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :metering 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_filter.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_filter 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_snmp.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_snmp 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/os_process.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :os_process 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/serializer.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :serializer 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vm_metric.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_metric 3 | end 4 | -------------------------------------------------------------------------------- /spec/models/cloud_volume_snapshot_spec.rb: -------------------------------------------------------------------------------- 1 | describe CloudVolumeSnapshot do 2 | end 3 | -------------------------------------------------------------------------------- /app/models/aliases/ems_network.rb: -------------------------------------------------------------------------------- 1 | ::EmsNetwork = ::ManageIQ::Providers::NetworkManager 2 | -------------------------------------------------------------------------------- /app/models/authentication_github.rb: -------------------------------------------------------------------------------- 1 | class AuthenticationGithub < Authentication 2 | end 3 | -------------------------------------------------------------------------------- /app/models/authentication_google.rb: -------------------------------------------------------------------------------- 1 | class AuthenticationGoogle < Authentication 2 | end 3 | -------------------------------------------------------------------------------- /app/models/authentication_open_id.rb: -------------------------------------------------------------------------------- 1 | class AuthenticationOpenId < Authentication 2 | end 3 | -------------------------------------------------------------------------------- /app/models/configuration_domain.rb: -------------------------------------------------------------------------------- 1 | class ConfigurationDomain < ConfigurationTag 2 | end 3 | -------------------------------------------------------------------------------- /app/models/configuration_realm.rb: -------------------------------------------------------------------------------- 1 | class ConfigurationRealm < ConfigurationTag 2 | end 3 | -------------------------------------------------------------------------------- /spec/factories/audit_event.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :audit_event 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/compute_node.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :compute_node 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/custom_event.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :custom_event 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/disk.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :disk do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/ems_refresh.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :ems_refresh 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/event_stream.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :event_stream 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/host_metric.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :host_metric 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/host_storage.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :host_storage 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/host_switch.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :host_switch 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/live_metric.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :live_metric 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/metering_vm.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :metering_vm 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_automate.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_automate 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_shortcut.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_shortcut 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/scan_history.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :scan_history 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/scan_result.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :scan_result 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/switch.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :switch do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/sysprep_file.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :sysprep_file 3 | end 4 | -------------------------------------------------------------------------------- /tools/classify_vms_by_folder: -------------------------------------------------------------------------------- 1 | Vm.all.each { |vm| vm.classify_with_parent_folder_path } 2 | -------------------------------------------------------------------------------- /app/models/authentication_allow_all.rb: -------------------------------------------------------------------------------- 1 | class AuthenticationAllowAll < Authentication 2 | end 3 | -------------------------------------------------------------------------------- /app/models/authentication_htpasswd.rb: -------------------------------------------------------------------------------- 1 | class AuthenticationHtpasswd < Authentication 2 | end 3 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/.rubocop_local.yml: -------------------------------------------------------------------------------- 1 | # GlobalVars: 2 | # AllowedVariables: 3 | -------------------------------------------------------------------------------- /spec/factories/authenticator.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :authenticator 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/chargeback_vm.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :chargeback_vm 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/cloud_database.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :cloud_database 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/condition_set.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :condition_set 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_build.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_build 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_limit.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_limit 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_quota.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_quota 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/file_depot_nfs.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :file_depot_nfs 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/file_depot_smb.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :file_depot_smb 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/firmware.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :firmware do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/ldap_management.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :ldap_management 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/lifecycle_event.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :lifecycle_event 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_action_set.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_action_set 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_bulk_import.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_bulk_import 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_reportable.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_reportable 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_user_scope.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_user_scope 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/network_group.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :network_group 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/pxe_menu.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :pxe_menu do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/request_event.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :request_event 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/service_generic.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :service_generic 3 | end 4 | -------------------------------------------------------------------------------- /app/models/aliases/ems_middleware.rb: -------------------------------------------------------------------------------- 1 | ::EmsMiddleware = ::ManageIQ::Providers::MiddlewareManager 2 | -------------------------------------------------------------------------------- /app/models/aliases/template_cloud.rb: -------------------------------------------------------------------------------- 1 | ::TemplateCloud = ManageIQ::Providers::CloudManager::Template 2 | -------------------------------------------------------------------------------- /app/models/condition_set.rb: -------------------------------------------------------------------------------- 1 | class ConditionSet < ApplicationRecord 2 | acts_as_miq_set 3 | end 4 | -------------------------------------------------------------------------------- /app/models/configuration_architecture.rb: -------------------------------------------------------------------------------- 1 | class ConfigurationArchitecture < ConfigurationTag 2 | end 3 | -------------------------------------------------------------------------------- /app/models/configuration_environment.rb: -------------------------------------------------------------------------------- 1 | class ConfigurationEnvironment < ConfigurationTag 2 | end 3 | -------------------------------------------------------------------------------- /app/models/container_volume_kubernetes.rb: -------------------------------------------------------------------------------- 1 | class ContainerVolumeKubernetes < ContainerVolume 2 | end 3 | -------------------------------------------------------------------------------- /app/models/miq_action_set.rb: -------------------------------------------------------------------------------- 1 | class MiqActionSet < ApplicationRecord 2 | acts_as_miq_set 3 | end 4 | -------------------------------------------------------------------------------- /app/models/scan_item_set.rb: -------------------------------------------------------------------------------- 1 | class ScanItemSet < ApplicationRecord 2 | acts_as_miq_set 3 | end 4 | -------------------------------------------------------------------------------- /app/models/template_xen.rb: -------------------------------------------------------------------------------- 1 | class TemplateXen < ManageIQ::Providers::InfraManager::Template 2 | end 3 | -------------------------------------------------------------------------------- /lib/miq_apache.rb: -------------------------------------------------------------------------------- 1 | require_relative 'miq_apache/config' 2 | require_relative 'miq_apache/control' 3 | -------------------------------------------------------------------------------- /spec/factories/advanced_setting.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :advanced_setting 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/asset_tag_import.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :asset_tag_import 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/auth_private_key.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :auth_private_key 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/binary_blob.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :binary_blob do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/configuration_tag.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :configuration_tag 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_env_var.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_env_var 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_serializer.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_serializer 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/drift_state.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :drift_state do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/host_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :host_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/iso_image.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :iso_image do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/ldap_domain.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :ldap_domain do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/ldap_group.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :ldap_group do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/ldap_server.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :ldap_server do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/ldap_user.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :ldap_user do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/miq_ae_workspace.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_ae_workspace 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_event_handler.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_event_handler 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_region_remote.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_region_remote 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/partition.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :partition do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/schema_migration.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :schema_migration 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/security_context.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :security_context 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vmdb_index.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vmdb_index do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/refs/tags/tag1: -------------------------------------------------------------------------------- 1 | fdb4bc8c22f4b3ca8279c2e1eb92670893473d05 2 | -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/refs/tags/tag2: -------------------------------------------------------------------------------- 1 | e316f7d7548ea8f874c872ff3be04f4e9849833b 2 | -------------------------------------------------------------------------------- /app/models/authentication_request_header.rb: -------------------------------------------------------------------------------- 1 | class AuthenticationRequestHeader < Authentication 2 | end 3 | -------------------------------------------------------------------------------- /app/models/configuration_compute_profile.rb: -------------------------------------------------------------------------------- 1 | class ConfigurationComputeProfile < ConfigurationTag 2 | end 3 | -------------------------------------------------------------------------------- /app/models/customization_script_medium.rb: -------------------------------------------------------------------------------- 1 | class CustomizationScriptMedium < CustomizationScript 2 | end 3 | -------------------------------------------------------------------------------- /app/models/customization_script_ptable.rb: -------------------------------------------------------------------------------- 1 | class CustomizationScriptPtable < CustomizationScript 2 | end 3 | -------------------------------------------------------------------------------- /app/models/ems_refresh/parsers/infra.rb: -------------------------------------------------------------------------------- 1 | module EmsRefresh::Parsers 2 | class Infra 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /app/models/vm_xen.rb: -------------------------------------------------------------------------------- 1 | class VmXen < ManageIQ::Providers::InfraManager::Vm 2 | supports :migrate 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/application_record.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :application_record 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/asset_details.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :asset_details do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/auth_userid_password.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :auth_userid_password 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/authentication_rhsm.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :authentication_rhsm 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/cloud_resource_quota.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :cloud_resource_quota 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/configuration_architecture.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define { factory :configuration_architecture } 2 | -------------------------------------------------------------------------------- /spec/factories/configuration_domain.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :configuration_domain 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/configuration_realm.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :configuration_realm 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_build_pod.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_build_pod 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_condition.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_condition 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_limit_item.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_limit_item 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_quota_item.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_quota_item 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/firewall_rule.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :firewall_rule do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/host_aggregate_host.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :host_aggregate_host 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/iso_datastore.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :iso_datastore do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/job_proxy_dispatcher.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :job_proxy_dispatcher 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_ae_field.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_ae_field do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/miq_ae_value.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_ae_value do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/miq_approval.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_approval do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/miq_priority_worker.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_priority_worker 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_reporting_worker.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_reporting_worker 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_widget_shortcut.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_widget_shortcut 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/policy_event.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :policy_event do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/policy_event_content.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :policy_event_content 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/pxe_menu_ipxe.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :pxe_menu_ipxe do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/registration_system.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :registration_system 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/registry_item.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :registry_item do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/retirement_manager.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :retirement_manager 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/scanning_operations.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :scanning_operations 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/storage_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :storage_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vim_performance_tag.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vim_performance_tag 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vm_migrate_workflow.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_migrate_workflow 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vm_reconfigure_task.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_reconfigure_task 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vmdb_database.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vmdb_database do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/vmdb_database_lock.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vmdb_database_lock 3 | end 4 | -------------------------------------------------------------------------------- /app/models/aliases/ems_physical_infra.rb: -------------------------------------------------------------------------------- 1 | ::EmsPhysicalInfra = ::ManageIQ::Providers::PhysicalInfraManager 2 | -------------------------------------------------------------------------------- /app/models/aliases/miq_event_catcher.rb: -------------------------------------------------------------------------------- 1 | ::MiqEventCatcher = ManageIQ::Providers::BaseManager::EventCatcher 2 | -------------------------------------------------------------------------------- /app/models/container_env_var.rb: -------------------------------------------------------------------------------- 1 | class ContainerEnvVar < ApplicationRecord 2 | belongs_to :container 3 | end 4 | -------------------------------------------------------------------------------- /app/models/miq_priority_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class MiqPriorityWorker::Runner < MiqQueueWorkerBase::Runner 2 | end 3 | -------------------------------------------------------------------------------- /app/models/miq_scsi_lun.rb: -------------------------------------------------------------------------------- 1 | class MiqScsiLun < ApplicationRecord 2 | belongs_to :miq_scsi_target 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/binary_blob_part.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :binary_blob_part do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/classification_import.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :classification_import 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/cloud_database_flavor.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :cloud_database_flavor 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/computer_system.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :computer_system do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/container_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_port_config.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_port_config 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_field_check_box.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_field_check_box 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_field_importer.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_field_importer 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_tab_serializer.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_tab_serializer 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_yaml_serializer.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_yaml_serializer 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/middleware_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :middleware_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_alert_status.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_alert_status do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/miq_cockpit_ws_worker.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_cockpit_ws_worker 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_queue_worker_base.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_queue_worker_base 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_smart_proxy_worker.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_smart_proxy_worker 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_web_service_worker.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_web_service_worker 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/notification_recipient.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :notification_recipient 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/operating_system.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :operating_system do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/pglogical_subscription.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :pglogical_subscription 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/pxe_image_type.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :pxe_image_type do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/resource_action.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :resource_action do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/service_resource.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :service_resource do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/settings_change.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :settings_change do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/storage_profile.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :storage_profile do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/vim_performance_daily.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vim_performance_daily 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vim_performance_trend.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vim_performance_trend 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vmdb_database_setting.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vmdb_database_setting 3 | end 4 | -------------------------------------------------------------------------------- /spec/rails_helper.rb: -------------------------------------------------------------------------------- 1 | # TODO: 2 | # * Move any Rails specific code and setup from spec_helper.rb to this file. 3 | -------------------------------------------------------------------------------- /app/models/aliases/miq_provision_cloud.rb: -------------------------------------------------------------------------------- 1 | ::MiqProvisionCloud = ::ManageIQ::Providers::CloudManager::Provision 2 | -------------------------------------------------------------------------------- /app/models/miq_reporting_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class MiqReportingWorker::Runner < MiqQueueWorkerBase::Runner 2 | end 3 | -------------------------------------------------------------------------------- /bin/rake: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require_relative '../config/boot' 3 | require 'rake' 4 | Rake.application.run 5 | -------------------------------------------------------------------------------- /config/ha_admin.yml: -------------------------------------------------------------------------------- 1 | --- 2 | failover_attempts: 10 3 | db_check_frequency: 300 4 | failover_check_frequency: 60 5 | -------------------------------------------------------------------------------- /db/fixtures/arbitration_settings.yml: -------------------------------------------------------------------------------- 1 | --- 2 | - :name: vm_images_meta_json 3 | :display_name: Default Images URL 4 | -------------------------------------------------------------------------------- /db/fixtures/miq_alert_default_action.yml: -------------------------------------------------------------------------------- 1 | --- 2 | options: 3 | :from: "" 4 | :to: [] 5 | action_type: email 6 | -------------------------------------------------------------------------------- /spec/factories/cloud_subnet_network_port.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :cloud_subnet_network_port 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/configuration_environment.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :configuration_environment 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_template.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_template do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/dialog_field_association.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_field_association 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_field_date_control.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_field_date_control 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_field_radio_button.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_field_radio_button 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_field_serializer.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_field_serializer 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_group_serializer.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_group_serializer 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_import_validator.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_import_validator 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/ems_cluster_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :ems_cluster_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/file_depot_ftp_anonymous.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :file_depot_ftp_anonymous 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/guest_application.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :guest_application do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/import_file_upload.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :import_file_upload do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/metering_container_image.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :metering_container_image 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_event_definition_set.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_event_definition_set 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_policy_content.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_policy_content do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/miq_report_result_detail.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_report_result_detail 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_widget_content.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_widget_content do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/pxe_menu_pxelinux.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :pxe_menu_pxelinux do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/resource_action_workflow.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :resource_action_workflow 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/service_template_generic.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :service_template_generic 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/storage_profile_storage.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :storage_profile_storage 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vim_performance_analysis.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vim_performance_analysis 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vim_performance_planning.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vim_performance_planning 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vim_performance_tag_daily.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vim_performance_tag_daily 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vim_performance_tag_value.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vim_performance_tag_value 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vm_cloud_reconfigure_task.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_cloud_reconfigure_task 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vmdb_database_connection.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vmdb_database_connection 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/widget_import_validator.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :widget_import_validator 3 | end 4 | -------------------------------------------------------------------------------- /spec/models/share_spec.rb: -------------------------------------------------------------------------------- 1 | describe Share do 2 | pending "add some examples to (or delete) #{__FILE__}" 3 | end 4 | -------------------------------------------------------------------------------- /app/models/aliases/miq_ems_refresh_worker.rb: -------------------------------------------------------------------------------- 1 | ::MiqEmsRefreshWorker = ManageIQ::Providers::BaseManager::RefreshWorker 2 | -------------------------------------------------------------------------------- /app/models/container_groups_container_services.rb: -------------------------------------------------------------------------------- 1 | class ContainerGroupsContainerServices < ApplicationRecord 2 | end 3 | -------------------------------------------------------------------------------- /app/models/host_switch.rb: -------------------------------------------------------------------------------- 1 | class HostSwitch < ApplicationRecord 2 | belongs_to :host 3 | belongs_to :switch 4 | end 5 | -------------------------------------------------------------------------------- /app/models/scan_result.rb: -------------------------------------------------------------------------------- 1 | class ScanResult < ApplicationRecord 2 | belongs_to :resource, :polymorphic => true 3 | end 4 | -------------------------------------------------------------------------------- /lib/vmdb_extensions.rb: -------------------------------------------------------------------------------- 1 | Dir.glob(File.expand_path(File.join(__dir__, "extensions", "*.rb"))).sort.each { |f| require f } 2 | -------------------------------------------------------------------------------- /spec/factories/chargeback_container_image.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :chargeback_container_image 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_group_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_group_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_node_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_node_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_volume_kubernetes.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_volume_kubernetes 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/customization_script.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :customization_script do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/customization_script_medium.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :customization_script_medium 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/customization_script_ptable.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :customization_script_ptable 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_field_text_area_box.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_field_text_area_box 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/ems_event.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :ems_event, :class => "EmsEvent" do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/metering_container_project.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :metering_container_project 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_event.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_event, :class => "MiqEvent" do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/miq_host_provision_workflow.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_host_provision_workflow 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_product_features_share.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_product_features_share 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_vim_broker_worker.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_vim_broker_worker do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/network_port_security_group.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :network_port_security_group 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/resource_action_serializer.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :resource_action_serializer 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vmdb_database_metric.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vmdb_database_metric do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /app/models/container_limit_item.rb: -------------------------------------------------------------------------------- 1 | class ContainerLimitItem < ApplicationRecord 2 | belongs_to :container_limit 3 | end 4 | -------------------------------------------------------------------------------- /app/models/host_storage.rb: -------------------------------------------------------------------------------- 1 | class HostStorage < ApplicationRecord 2 | belongs_to :host 3 | belongs_to :storage 4 | end 5 | -------------------------------------------------------------------------------- /app/models/openscap_rule_result.rb: -------------------------------------------------------------------------------- 1 | class OpenscapRuleResult < ApplicationRecord 2 | belongs_to :openscap_result 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/chargeback_container_project.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :chargeback_container_project 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/configuration_compute_profile.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :configuration_compute_profile 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_project_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_project_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_service_port_config.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_service_port_config 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/dialog_field_date_time_control.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_field_date_time_control 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/middleware_diagnostic_report.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :middleware_diagnostic_report 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/middleware_server_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :middleware_server_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/operating_system_flavor.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :operating_system_flavor do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/orchestration_stack_parameter.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :orchestration_stack_parameter 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/service_template_ansible_tower.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :service_template_ansible_tower 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/vm_cloud_reconfigure_request.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_cloud_reconfigure_request 3 | end 4 | -------------------------------------------------------------------------------- /spec/fixtures/files/upload_image.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ailisp/manageiq/master/spec/fixtures/files/upload_image.png -------------------------------------------------------------------------------- /app/models/aliases/workers/ems_refresh_worker.rb: -------------------------------------------------------------------------------- 1 | ::EmsRefreshWorker = ManageIQ::Providers::BaseManager::RefreshWorker::Runner 2 | -------------------------------------------------------------------------------- /app/models/ldap_group.rb: -------------------------------------------------------------------------------- 1 | class LdapGroup < ApplicationRecord 2 | belongs_to :ldap_domain 3 | # acts_as_miq_taggable 4 | end 5 | -------------------------------------------------------------------------------- /app/models/miq_ui_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class MiqUiWorker::Runner < MiqWorker::Runner 2 | include MiqWebServerRunnerMixin 3 | end 4 | -------------------------------------------------------------------------------- /app/models/security_context.rb: -------------------------------------------------------------------------------- 1 | class SecurityContext < ApplicationRecord 2 | belongs_to :resource, :polymorphic => true 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/notification.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :notification do 3 | notification_type 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/vim_performance_operating_range.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vim_performance_operating_range 3 | end 4 | -------------------------------------------------------------------------------- /app/channels/application_cable/channel.rb: -------------------------------------------------------------------------------- 1 | module ApplicationCable 2 | class Channel < ActionCable::Channel::Base 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /app/models/miq_ems_metrics_processor_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class MiqEmsMetricsProcessorWorker::Runner < MiqQueueWorkerBase::Runner 2 | end 3 | -------------------------------------------------------------------------------- /app/models/miq_report_result_detail.rb: -------------------------------------------------------------------------------- 1 | class MiqReportResultDetail < ApplicationRecord 2 | belongs_to :miq_report_result 3 | end 4 | -------------------------------------------------------------------------------- /app/models/tagging.rb: -------------------------------------------------------------------------------- 1 | class Tagging < ApplicationRecord 2 | belongs_to :tag 3 | belongs_to :taggable, :polymorphic => true 4 | end 5 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/lib/manageiq/providers/%provider_name%.rb: -------------------------------------------------------------------------------- 1 | require "manageiq/providers/<%= provider_name %>/engine" 2 | -------------------------------------------------------------------------------- /spec/factories/authentication_orchestration_stack.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :authentication_orchestration_stack 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/blacklisted_event.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :blacklisted_event do 3 | enabled true 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/container_groups_container_services.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_groups_container_services 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_template_parameter.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_template_parameter do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/dialog_field_association_validator.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dialog_field_association_validator 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/ext_management_system_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :ext_management_system_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/load_balancer_listener_pool.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :load_balancer_listener_pool do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/middleware_datasource_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :middleware_datasource_performance 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/physical_server.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :physical_server do 3 | vendor "lenovo" 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/physical_server_provision_request.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :physical_server_provision_request 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/physical_server_provision_workflow.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :physical_server_provision_workflow 3 | end 4 | -------------------------------------------------------------------------------- /spec/i18n/placeholders_spec.rb: -------------------------------------------------------------------------------- 1 | describe :placeholders do 2 | include_examples :placeholders, Rails.root.join('locale').to_s 3 | end 4 | -------------------------------------------------------------------------------- /app/models/aliases/miq_provision_cloud_workflow.rb: -------------------------------------------------------------------------------- 1 | ::MiqProvisionCloudWorkflow = ::ManageIQ::Providers::CloudManager::ProvisionWorkflow 2 | -------------------------------------------------------------------------------- /app/models/aliases/miq_provision_infra_workflow.rb: -------------------------------------------------------------------------------- 1 | ::MiqProvisionInfraWorkflow = ::ManageIQ::Providers::InfraManager::ProvisionWorkflow 2 | -------------------------------------------------------------------------------- /app/models/middleware_diagnostic_report.rb: -------------------------------------------------------------------------------- 1 | class MiddlewareDiagnosticReport < ApplicationRecord 2 | belongs_to :middleware_server 3 | end 4 | -------------------------------------------------------------------------------- /lib/generators/provider/USAGE: -------------------------------------------------------------------------------- 1 | Description: 2 | Create or update provider 3 | 4 | Example: 5 | rails generate provider VendorName 6 | -------------------------------------------------------------------------------- /spec/factories/bottleneck_event.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :bottleneck_event, :class => "BottleneckEvent" do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/dynamic_dialog_field_value_processor.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :dynamic_dialog_field_value_processor 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/load_balancer_pool_member_pool.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :load_balancer_pool_member_pool do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/miq_provision_request_template.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_provision_request_template do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/miq_queue.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_queue do 3 | state 'ready' 4 | args [] 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/miq_region.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_region do 3 | sequence(:region) { |reg| reg } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /app/models/aliases/miq_ems_metrics_collector_worker.rb: -------------------------------------------------------------------------------- 1 | ::MiqEmsMetricsCollectorWorker = ManageIQ::Providers::BaseManager::MetricsCollectorWorker 2 | -------------------------------------------------------------------------------- /app/models/cloud_tenant_flavor.rb: -------------------------------------------------------------------------------- 1 | class CloudTenantFlavor < ApplicationRecord 2 | belongs_to :cloud_tenant 3 | belongs_to :flavor 4 | end 5 | -------------------------------------------------------------------------------- /app/models/container_condition.rb: -------------------------------------------------------------------------------- 1 | class ContainerCondition < ApplicationRecord 2 | belongs_to :container_entity, :polymorphic => true 3 | end 4 | -------------------------------------------------------------------------------- /app/models/container_service_port_config.rb: -------------------------------------------------------------------------------- 1 | class ContainerServicePortConfig < ApplicationRecord 2 | belongs_to :container_service 3 | end 4 | -------------------------------------------------------------------------------- /app/models/host_aggregate_host.rb: -------------------------------------------------------------------------------- 1 | class HostAggregateHost < ApplicationRecord 2 | belongs_to :host 3 | belongs_to :host_aggregate 4 | end 5 | -------------------------------------------------------------------------------- /app/models/miq_web_service_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class MiqWebServiceWorker::Runner < MiqWorker::Runner 2 | include MiqWebServerRunnerMixin 3 | end 4 | -------------------------------------------------------------------------------- /db/fixtures/users.yml: -------------------------------------------------------------------------------- 1 | --- 2 | - :name: Administrator 3 | :userid: admin 4 | :password: smartvm 5 | :group: EvmGroup-super_administrator 6 | -------------------------------------------------------------------------------- /lib/resource_feeder/lib/resource_feeder.rb: -------------------------------------------------------------------------------- 1 | $:.push(File.dirname(__FILE__)) 2 | require 'resource_feeder/rss' 3 | require 'resource_feeder/atom' 4 | -------------------------------------------------------------------------------- /spec/factories/authentication_configuration_script_base.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :authentication_configuration_script_base 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/automate_workspace.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :automate_workspace do 3 | user 4 | tenant 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/endpoint.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :endpoint do 3 | port 443 4 | hostname "example.com" 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/load_balancer_health_check_member.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :load_balancer_health_check_member do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/miq_policy_set.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_policy_set do 3 | description "Test Policy Set" 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/miq_provision_configured_system_request.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_provision_configured_system_request 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/miq_provision_configured_system_workflow.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_provision_configured_system_workflow 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/network.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :network do 3 | sequence(:ipaddress) { |n| ip_from_seq(n) } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/server_role.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :server_role do 3 | sequence(:name) { |i| "role#{i}"} 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/vm_performance.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_performance do 3 | timestamp { Time.now.utc } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /tools/ci/setup_ruby_env.sh: -------------------------------------------------------------------------------- 1 | ./tools/ci/setup_ruby_environment.rb 2 | export BUNDLE_WITHOUT=development 3 | export BUNDLE_GEMFILE=${PWD}/Gemfile 4 | -------------------------------------------------------------------------------- /app/models/aliases/ems_refresh/refreshers/base_refresher.rb: -------------------------------------------------------------------------------- 1 | ::EmsRefresh::Refreshers::BaseRefresher = ManageIQ::Providers::BaseManager::Refresher 2 | -------------------------------------------------------------------------------- /app/models/miq_widget_shortcut.rb: -------------------------------------------------------------------------------- 1 | class MiqWidgetShortcut < ApplicationRecord 2 | belongs_to :miq_widget 3 | belongs_to :miq_shortcut 4 | end 5 | -------------------------------------------------------------------------------- /bin/bundle: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__) 3 | load Gem.bin_path('bundler', 'bundle') 4 | -------------------------------------------------------------------------------- /config/human_locale_names.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | human_locale_names: 3 | en: English 4 | es: Español 5 | fr: Français 6 | ja: 日本語 7 | zh_CN: 简体中文 8 | -------------------------------------------------------------------------------- /spec/factories/automation_request.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :automation_request do 3 | request_type "automation" 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /tools/ci/after_failure.sh: -------------------------------------------------------------------------------- 1 | set -v 2 | 3 | echo "Errors and warnings in log files" 4 | echo log/* 5 | egrep -i "warn|error" log/*.log 6 | 7 | set +v 8 | -------------------------------------------------------------------------------- /.rubocop_cc.yml: -------------------------------------------------------------------------------- 1 | inherit_from: 2 | # this is downloaded by .codeclimate.yml 3 | - .rubocop_base.yml 4 | - .rubocop_cc_base.yml 5 | - .rubocop_local.yml 6 | -------------------------------------------------------------------------------- /app/models/aliases/template_infra.rb: -------------------------------------------------------------------------------- 1 | require 'manageiq/providers/infra_manager/template' 2 | ::TemplateInfra = ManageIQ::Providers::InfraManager::Template 3 | -------------------------------------------------------------------------------- /app/models/container_port_config.rb: -------------------------------------------------------------------------------- 1 | class ContainerPortConfig < ApplicationRecord 2 | # :port, :host_port, :protocol 3 | belongs_to :container 4 | end 5 | -------------------------------------------------------------------------------- /app/models/dialog_yaml_serializer.rb: -------------------------------------------------------------------------------- 1 | class DialogYamlSerializer < DialogSerializer 2 | def serialize(dialogs) 3 | super.to_yaml 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/automation_manager/authentication.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::AutomationManager::Authentication < Authentication 2 | end 3 | -------------------------------------------------------------------------------- /app/models/miq_widget_content.rb: -------------------------------------------------------------------------------- 1 | class MiqWidgetContent < ApplicationRecord 2 | belongs_to :miq_widget 3 | belongs_to :miq_report_result 4 | end 5 | -------------------------------------------------------------------------------- /app/models/storage_profile_storage.rb: -------------------------------------------------------------------------------- 1 | class StorageProfileStorage < ApplicationRecord 2 | belongs_to :storage_profile 3 | belongs_to :storage 4 | end 5 | -------------------------------------------------------------------------------- /app/models/subnet.rb: -------------------------------------------------------------------------------- 1 | class Subnet < ApplicationRecord 2 | include NewWithTypeStiMixin 3 | 4 | acts_as_miq_taggable 5 | 6 | belongs_to :lan 7 | end 8 | -------------------------------------------------------------------------------- /bin/eslint: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | ESLINT="node_modules/.bin/eslint" 3 | 4 | cd `dirname $0`/.. 5 | 6 | $ESLINT "$@" app/assets/javascripts/ spec/javascripts/ 7 | -------------------------------------------------------------------------------- /config/cable.yml.sample: -------------------------------------------------------------------------------- 1 | production: 2 | adapter: postgresql 3 | 4 | development: 5 | adapter: postgresql 6 | 7 | test: 8 | adapter: postgresql 9 | -------------------------------------------------------------------------------- /spec/factories/container_deployment.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_deployment, :class => "ContainerDeployment" do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/lan.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :lan do 3 | sequence(:name) { |n| "Lan #{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/models/miq_product_features_share_spec.rb: -------------------------------------------------------------------------------- 1 | describe MiqProductFeaturesShare do 2 | pending "add some examples to (or delete) #{__FILE__}" 3 | end 4 | -------------------------------------------------------------------------------- /tools/ci/setup_ruby_environment.rb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require_relative '../../lib/manageiq/environment' 3 | ManageIQ::Environment.install_bundler 4 | -------------------------------------------------------------------------------- /app/models/configuration_script.rb: -------------------------------------------------------------------------------- 1 | class ConfigurationScript < ConfigurationScriptBase 2 | def self.base_model 3 | ConfigurationScript 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /app/models/ldap_management.rb: -------------------------------------------------------------------------------- 1 | class LdapManagement < ApplicationRecord 2 | belongs_to :ldap_user 3 | belongs_to :manager, :class_name => "LdapUser" 4 | end 5 | -------------------------------------------------------------------------------- /lib/workers/bin/evm_server.rb: -------------------------------------------------------------------------------- 1 | require File.expand_path("../../../config/environment", __dir__) 2 | require "workers/evm_server" 3 | 4 | EvmServer.start(*ARGV) 5 | -------------------------------------------------------------------------------- /spec/factories/cloud_tenant_flavor.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :cloud_tenant_flavor do 3 | # mapping of cloud_tenant to flavor 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/miq_ems_refresh_core_worker.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_ems_refresh_core_worker do 3 | pid { Process.pid } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /app/models/file_depot_ftp_anonymous.rb: -------------------------------------------------------------------------------- 1 | class FileDepotFtpAnonymous < FileDepotFtp 2 | def login_credentials 3 | ["anonymous", "anonymous"] 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/automation_manager/configured_system.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::AutomationManager::ConfiguredSystem < ::ConfiguredSystem 2 | end 3 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/container_manager/container_template.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::ContainerManager::ContainerTemplate < ContainerTemplate 2 | end 3 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/physical_infra_manager/refresh_parser.rb: -------------------------------------------------------------------------------- 1 | module ManageIQ::Providers 2 | class PhysicalInfraManager::RefreshParser 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /app/models/miq_product_features_share.rb: -------------------------------------------------------------------------------- 1 | class MiqProductFeaturesShare < ApplicationRecord 2 | belongs_to :miq_product_feature 3 | belongs_to :share 4 | end 5 | -------------------------------------------------------------------------------- /app/models/orchestration_stack_resource.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationStackResource < ApplicationRecord 2 | belongs_to :stack, :class_name => "OrchestrationStack" 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/container_deployment_node.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_deployment_node, :class => "ContainerDeploymentNode" do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/database_backup.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :database_backup do 3 | sequence(:name) { |val| "db_backup_#{val}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/file_depot.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :file_depot do 3 | name "File Depot" 4 | uri "nfs://somehost/export" 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/rss_feed.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :rss_feed do 3 | sequence(:name) { |n| "feed_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/models/configuration_location_spec.rb: -------------------------------------------------------------------------------- 1 | describe ConfigurationLocation do 2 | it { expect(described_class.new(:title => "x").display_name).to eq("x") } 3 | end 4 | -------------------------------------------------------------------------------- /app/models/auth_token.rb: -------------------------------------------------------------------------------- 1 | class AuthToken < Authentication 2 | def auth_key=(val) 3 | @auth_changed = true if val != auth_key 4 | super(val) 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/automation_manager/orchestration_stack.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::AutomationManager::OrchestrationStack < ::OrchestrationStack 2 | end 3 | -------------------------------------------------------------------------------- /app/models/orchestration_stack_parameter.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationStackParameter < ApplicationRecord 2 | belongs_to :stack, :class_name => "OrchestrationStack" 3 | end 4 | -------------------------------------------------------------------------------- /app/models/policy_event_content.rb: -------------------------------------------------------------------------------- 1 | class PolicyEventContent < ApplicationRecord 2 | belongs_to :resource, :polymorphic => true 3 | belongs_to :policy_event 4 | end 5 | -------------------------------------------------------------------------------- /bin/rails: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | APP_PATH = File.expand_path('../../config/application', __FILE__) 3 | require_relative '../config/boot' 4 | require 'rails/commands' 5 | -------------------------------------------------------------------------------- /spec/factories/resource_pool.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :resource_pool do 3 | sequence(:name) { |n| "rp_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/tag.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :tag do 3 | sequence(:name) { |n| "/namespace/cat/tag_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/models/miq_report/seeding_spec.rb: -------------------------------------------------------------------------------- 1 | describe MiqReport do 2 | context "Seeding" do 3 | include_examples(".seed called multiple times", 147) 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /.yardopts: -------------------------------------------------------------------------------- 1 | app/models/mixins/supports_feature_mixin.rb 2 | app/models/manager_refresh 3 | app/models/container_label_tag_mapping.rb 4 | app/models/container_label_tag_mapping 5 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/automation_manager/configuration_script.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::AutomationManager::ConfigurationScript < ::ConfigurationScript 2 | end 3 | -------------------------------------------------------------------------------- /spec/factories/ldap_region.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :ldap_region do 3 | name "default" 4 | description "Default Ldap Region" 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/miq_schedule_worker.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_schedule_worker, :parent => :miq_worker, :class => "MiqScheduleWorker" do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/resource_groups.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :resource_group do 3 | sequence(:name) { |n| "rg_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/models/configuration_organization_spec.rb: -------------------------------------------------------------------------------- 1 | describe ConfigurationOrganization do 2 | it { expect(described_class.new(:title => "x").display_name).to eq("x") } 3 | end 4 | -------------------------------------------------------------------------------- /tools/ci/before_install.sh: -------------------------------------------------------------------------------- 1 | set -v 2 | 3 | source $TRAVIS_BUILD_DIR/tools/ci/setup_vmdb_configs.sh 4 | source $TRAVIS_BUILD_DIR/tools/ci/setup_ruby_env.sh 5 | 6 | set +v 7 | -------------------------------------------------------------------------------- /app/models/dialog_field_text_area_box.rb: -------------------------------------------------------------------------------- 1 | class DialogFieldTextAreaBox < DialogFieldTextBox 2 | AUTOMATE_VALUE_FIELDS = %w(required read_only visible description).freeze 3 | end 4 | -------------------------------------------------------------------------------- /app/models/load_balancer_listener_pool.rb: -------------------------------------------------------------------------------- 1 | class LoadBalancerListenerPool < ApplicationRecord 2 | belongs_to :load_balancer_listener 3 | belongs_to :load_balancer_pool 4 | end 5 | -------------------------------------------------------------------------------- /config.ru: -------------------------------------------------------------------------------- 1 | # This file is used by Rack-based servers to start the application. 2 | 3 | require ::File.expand_path('../config/environment', __FILE__) 4 | run(Vmdb::Application) 5 | -------------------------------------------------------------------------------- /spec/factories/auth_key_pair_cloud.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :auth_key_pair_cloud, :class => "ManageIQ::Providers::CloudManager::AuthKeyPair" do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/git_repositories.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :git_repository do 3 | sequence(:name) { |n| "git_repo_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/snapshot.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :snapshot do 3 | vm_or_template { create(:vm_vmware) } 4 | create_time { 1.minute.ago } 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /app/models/middleware_datasource_performance.rb: -------------------------------------------------------------------------------- 1 | class MiddlewareDatasourcePerformance < MiddlewarePerformance 2 | def self.model_class 3 | MiddlewareDatasource 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /app/models/middleware_server_performance.rb: -------------------------------------------------------------------------------- 1 | class MiddlewareServerPerformance < MiddlewarePerformance 2 | 3 | def self.model_class 4 | MiddlewareServer 5 | end 6 | 7 | end 8 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/.rspec: -------------------------------------------------------------------------------- 1 | --require manageiq/spec/spec_helper 2 | --require spec_helper 3 | --color 4 | --order random 5 | --exclude-pattern "spec/manageiq/**/*_spec.rb" 6 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/.rubocop_cc.yml: -------------------------------------------------------------------------------- 1 | inherit_from: 2 | # this is downloaded by .codeclimate.yml 3 | - .rubocop_base.yml 4 | - .rubocop_cc_base.yml 5 | - .rubocop_local.yml 6 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/app/models/manageiq/providers/cloud_manager.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::<%= class_name %>::CloudManager < ManageIQ::Providers::CloudManager 2 | end 3 | -------------------------------------------------------------------------------- /spec/factories/generic_object.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :generic_object do 3 | sequence(:name) { |n| "generic_object_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/miq_enterprise.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_enterprise do 3 | sequence(:name) { |n| "miq_enterprise_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/picture.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :picture do 3 | extension 'png' 4 | after(:build) do |x| 5 | x.content = 'foo' 6 | end 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /spec/factories/system_service.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :system_service do 3 | sequence(:name) { |n| "system_service_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/config: -------------------------------------------------------------------------------- 1 | [core] 2 | repositoryformatversion = 0 3 | filemode = true 4 | bare = true 5 | ignorecase = true 6 | precomposeunicode = false 7 | -------------------------------------------------------------------------------- /app/models/authentication_orchestration_stack.rb: -------------------------------------------------------------------------------- 1 | class AuthenticationOrchestrationStack < ApplicationRecord 2 | belongs_to :authentication 3 | belongs_to :orchestration_stack 4 | end 5 | -------------------------------------------------------------------------------- /app/models/load_balancer_pool_member_pool.rb: -------------------------------------------------------------------------------- 1 | class LoadBalancerPoolMemberPool < ApplicationRecord 2 | belongs_to :load_balancer_pool 3 | belongs_to :load_balancer_pool_member 4 | end 5 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/automation_manager/configuration_script_source.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::AutomationManager::ConfigurationScriptSource < ConfigurationScriptSource 2 | end 3 | -------------------------------------------------------------------------------- /app/models/miq_queue_worker_base.rb: -------------------------------------------------------------------------------- 1 | class MiqQueueWorkerBase < MiqWorker 2 | require_nested :Runner 3 | 4 | def self.queue_priority 5 | MiqQueue::MIN_PRIORITY 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/miq_smart_proxy_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class MiqSmartProxyWorker::Runner < MiqQueueWorkerBase::Runner 2 | self.delay_startup_for_vim_broker = true # NOTE: For smartproxy role 3 | end 4 | -------------------------------------------------------------------------------- /certs/v2_key.dev: -------------------------------------------------------------------------------- 1 | --- 2 | :EZCRYPTO KEY FILE: KEEP THIS SECURE ! 3 | :created: 2014-02-28 09:59:47 -0500 4 | :algorithm: aes-256-cbc 5 | :key: uXfIgSAUq5Oz8goc/zI8HOOo0SI++Sd9mfpgBanYIM4= 6 | -------------------------------------------------------------------------------- /config/environment.rb: -------------------------------------------------------------------------------- 1 | # Load the rails application 2 | require File.expand_path('../application', __FILE__) 3 | 4 | # Initialize the rails application 5 | Vmdb::Application.initialize! 6 | -------------------------------------------------------------------------------- /spec/factories/auth_key_pair_amazon.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :auth_key_pair_amazon, :class => "ManageIQ::Providers::Amazon::CloudManager::AuthKeyPair" do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/container_image.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_image do 3 | sequence(:name) { |n| "container_image_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/container_routes.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_route do 3 | sequence(:name) { |n| "container_route_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/container_volume.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_volume do 3 | sequence(:name) { |n| "container_volume_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/log_file.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :log_file do 3 | state "collecting" 4 | historical true 5 | description "Default logfile" 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/middleware_deployment.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :middleware_deployment do 3 | ext_management_system 4 | name "A Middleware Deployment" 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/miq_ae_namespace.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_ae_namespace do 3 | sequence(:name) { |n| "miq_ae_namespace_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/miq_compare.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_compare do 3 | report nil 4 | options nil 5 | initialize_with { new(options, report) } 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/zone.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :zone do 3 | sequence(:name) { |n| "Zone #{n}" } 4 | sequence(:description) { |n| "Zone #{n}" } 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /tools/purge_host_unknown_records.rb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require File.expand_path('../config/environment', __dir__) 3 | 4 | class HostUnknown < Host; end 5 | HostUnknown.destroy_all 6 | -------------------------------------------------------------------------------- /app/models/file_depot_nfs.rb: -------------------------------------------------------------------------------- 1 | class FileDepotNfs < FileDepot 2 | def self.requires_credentials? 3 | false 4 | end 5 | 6 | def self.uri_prefix 7 | "nfs" 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/automation_manager/configuration_script_payload.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::AutomationManager::ConfigurationScriptPayload < ::ConfigurationScriptPayload 2 | end 3 | -------------------------------------------------------------------------------- /app/models/miq_scsi_target.rb: -------------------------------------------------------------------------------- 1 | class MiqScsiTarget < ApplicationRecord 2 | serialize :address 3 | 4 | belongs_to :guest_device 5 | has_many :miq_scsi_luns, :dependent => :destroy 6 | end 7 | -------------------------------------------------------------------------------- /app/models/orchestration_template/orchestration_parameter_boolean.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationTemplate 2 | class OrchestrationParameterBoolean < OrchestrationParameterConstraint 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /config/preinitializer.rb: -------------------------------------------------------------------------------- 1 | # Optional logging of requires 2 | if ENV["REQUIRE_LOG"] 3 | $req_log_path = File.join(File.dirname(__FILE__), %w(.. log)) 4 | require 'require_with_logging' 5 | end 6 | -------------------------------------------------------------------------------- /lib/extensions/ar_adapter.rb: -------------------------------------------------------------------------------- 1 | require "active_record/connection_adapters/postgresql_adapter" 2 | Dir.glob(File.expand_path(File.join(__dir__, "ar_adapter", "*.rb"))).sort.each { |f| require f } 3 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/lib/manageiq-providers-%provider_name%.rb: -------------------------------------------------------------------------------- 1 | require "manageiq/providers/<%= provider_name %>/engine" 2 | require "manageiq/providers/<%= provider_name %>/version" 3 | -------------------------------------------------------------------------------- /spec/factories/auth_key_pair_openstack.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :auth_key_pair_openstack, :class => "ManageIQ::Providers::Openstack::CloudManager::AuthKeyPair" do 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/container_project.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_project do 3 | sequence(:name) { |n| "container_project_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/container_services.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_service do 3 | sequence(:name) { |n| "container_service_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/persistent_volume.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :persistent_volume do 3 | sequence(:name) { |n| "persistent_volume_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/physical_infra_manager.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :generic_physical_infra, 3 | :class => "ManageIQ::Providers::PhysicalInfraManager" do 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/service_template_catalog.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :service_template_catalog do 3 | sequence(:name) { |num| "service_template_catalog_#{num}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/support/options_request.rb: -------------------------------------------------------------------------------- 1 | module ActionDispatch::Integration::RequestHelpers 2 | def options(path, headers = nil) 3 | process :options, path, :headers => headers 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /app/models/aliases/workers/event_catcher.rb: -------------------------------------------------------------------------------- 1 | ::EventCatcher = ManageIQ::Providers::BaseManager::EventCatcher::Runner 2 | ::EventCatcherHandledException = ::EventCatcher::EventCatcherHandledException 3 | -------------------------------------------------------------------------------- /app/models/orchestration_stack_output.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationStackOutput < ApplicationRecord 2 | belongs_to :stack, :class_name => "OrchestrationStack" 3 | 4 | alias_attribute :name, :key 5 | end 6 | -------------------------------------------------------------------------------- /app/models/orchestration_template/orchestration_parameter_multiline.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationTemplate 2 | class OrchestrationParameterMultiline < OrchestrationParameterConstraint 3 | end 4 | end 5 | -------------------------------------------------------------------------------- /spec/factories/host_service_group.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :host_service_group do 3 | sequence(:name) { |n| "host_service_group_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/miq_template.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_template do 3 | name "ubuntu-16.04-stable" 4 | location "Minneapolis, MN" 5 | vendor "openstack" 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /tools/ci/setup_vmdb_configs.rb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require_relative '../../lib/manageiq/environment' 3 | ManageIQ::Environment.ensure_config_files 4 | ManageIQ::Environment.create_database_user 5 | -------------------------------------------------------------------------------- /app/models/asset_details.rb: -------------------------------------------------------------------------------- 1 | class AssetDetails < ApplicationRecord 2 | include NewWithTypeStiMixin 3 | 4 | acts_as_miq_taggable 5 | 6 | belongs_to :physical_server, :polymorphic => true 7 | end 8 | -------------------------------------------------------------------------------- /app/models/authentication_configuration_script_base.rb: -------------------------------------------------------------------------------- 1 | class AuthenticationConfigurationScriptBase < ApplicationRecord 2 | belongs_to :authentication 3 | belongs_to :configuration_script_base 4 | end 5 | -------------------------------------------------------------------------------- /app/models/load_balancer_health_check_member.rb: -------------------------------------------------------------------------------- 1 | class LoadBalancerHealthCheckMember < ApplicationRecord 2 | belongs_to :load_balancer_health_check 3 | belongs_to :load_balancer_pool_member 4 | end 5 | -------------------------------------------------------------------------------- /app/models/miq_event_handler.rb: -------------------------------------------------------------------------------- 1 | class MiqEventHandler < MiqQueueWorkerBase 2 | require_nested :Runner 3 | 4 | self.required_roles = ["event"] 5 | self.default_queue_name = "ems" 6 | end 7 | -------------------------------------------------------------------------------- /app/models/miq_generic_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class MiqGenericWorker::Runner < MiqQueueWorkerBase::Runner 2 | self.delay_startup_for_vim_broker = true # NOTE: For ems_operations and smartstate roles 3 | end 4 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/.rspec_ci: -------------------------------------------------------------------------------- 1 | --require manageiq/spec/spec_helper 2 | --require spec_helper 3 | --color 4 | --order random 5 | --profile 25 6 | --exclude-pattern "spec/manageiq/**/*_spec.rb" 7 | -------------------------------------------------------------------------------- /spec/factories/container_image_registry.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :container_image_registry do 3 | sequence(:name) { |n| "image_registry_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/scan_item_set.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :scan_item_set do 3 | sequence(:name) { |i| "scan_item_set#{i}" } 4 | description 'ScanItemSet description' 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/models/manageiq/providers/embedded_ansible/automation_manager_spec.rb: -------------------------------------------------------------------------------- 1 | describe ManageIQ::Providers::EmbeddedAnsible::AutomationManager do 2 | it_behaves_like 'ansible automation_manager' 3 | end 4 | -------------------------------------------------------------------------------- /app/models/dialog_field_association.rb: -------------------------------------------------------------------------------- 1 | class DialogFieldAssociation < ActiveRecord::Base 2 | belongs_to :trigger, :class_name => :DialogField 3 | belongs_to :respond, :class_name => :DialogField 4 | end 5 | -------------------------------------------------------------------------------- /app/models/iso_image.rb: -------------------------------------------------------------------------------- 1 | class IsoImage < ApplicationRecord 2 | belongs_to :iso_datastore 3 | belongs_to :pxe_image_type 4 | 5 | has_many :customization_templates, :through => :pxe_image_type 6 | end 7 | -------------------------------------------------------------------------------- /lib/extensions/ar_column_names.rb: -------------------------------------------------------------------------------- 1 | module ActiveRecord 2 | class Base 3 | def self.column_names_symbols 4 | @column_names_symbols ||= column_names.collect(&:to_sym) 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/configuration_location.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :configuration_location do 3 | sequence(:name) { |n| "configuration_location#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/template_google.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory(:template_google, :class => "ManageIQ::Providers::Google::CloudManager::Template", :parent => :template_cloud) { vendor "google" } 3 | end 4 | -------------------------------------------------------------------------------- /spec/factories/template_redhat.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory(:template_redhat, :class => "ManageIQ::Providers::Redhat::InfraManager::Template", :parent => :template_infra) { vendor "redhat" } 3 | end 4 | -------------------------------------------------------------------------------- /app/models/host_service_group.rb: -------------------------------------------------------------------------------- 1 | class HostServiceGroup < ApplicationRecord 2 | has_many :filesystems, :dependent => :nullify 3 | has_many :system_services, :dependent => :nullify 4 | belongs_to :host 5 | end 6 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_automation_manager/inventory_group.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAutomationManager::InventoryGroup < ManageIQ::Providers::AutomationManager::InventoryGroup 2 | end 3 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/external_automation_manager/inventory_group.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::ExternalAutomationManager::InventoryGroup < ManageIQ::Providers::AutomationManager::InventoryGroup 2 | end 3 | -------------------------------------------------------------------------------- /app/models/windows_image.rb: -------------------------------------------------------------------------------- 1 | class WindowsImage < ApplicationRecord 2 | belongs_to :pxe_server 3 | belongs_to :pxe_image_type 4 | 5 | has_many :customization_templates, :through => :pxe_image_type 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/persistent_volume_claim.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :persistent_volume_claim do 3 | sequence(:name) { |n| "persistent_volume_claim_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/vim_performance_state.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vim_performance_state, :class => :VimPerformanceState do 3 | timestamp { Time.now.utc } 4 | state_data {{}} 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/vm_vmware_cloud.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_vmware_cloud, :class => "ManageIQ::Providers::Vmware::CloudManager::Vm", :parent => :vm_cloud do 3 | vendor "vmware" 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /app/models/cloud_subnet_network_port.rb: -------------------------------------------------------------------------------- 1 | class CloudSubnetNetworkPort < ApplicationRecord 2 | self.table_name = "cloud_subnets_network_ports" 3 | 4 | belongs_to :cloud_subnet 5 | belongs_to :network_port 6 | end 7 | -------------------------------------------------------------------------------- /app/models/firmware.rb: -------------------------------------------------------------------------------- 1 | class Firmware < ApplicationRecord 2 | include NewWithTypeStiMixin 3 | 4 | acts_as_miq_taggable 5 | 6 | belongs_to :resource, :polymorphic => true 7 | belongs_to :guest_device 8 | end 9 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_automation_manager/authentication.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAutomationManager::Authentication < 2 | ManageIQ::Providers::AutomationManager::Authentication 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_automation_manager/configured_system.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAutomationManager::ConfiguredSystem < ManageIQ::Providers::AutomationManager::ConfiguredSystem 2 | end 3 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/external_automation_manager/authentication.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::ExternalAutomationManager::Authentication < 2 | ManageIQ::Providers::AutomationManager::Authentication 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/external_automation_manager/configured_system.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::ExternalAutomationManager::ConfiguredSystem < ManageIQ::Providers::AutomationManager::ConfiguredSystem 2 | end 3 | -------------------------------------------------------------------------------- /app/models/miq_reporting_worker.rb: -------------------------------------------------------------------------------- 1 | class MiqReportingWorker < MiqQueueWorkerBase 2 | require_nested :Runner 3 | 4 | self.required_roles = ["reporting"] 5 | self.default_queue_name = "reporting" 6 | end 7 | -------------------------------------------------------------------------------- /app/models/physical_server/operations.rb: -------------------------------------------------------------------------------- 1 | module PhysicalServer::Operations 2 | extend ActiveSupport::Concern 3 | 4 | include_concern 'Power' 5 | include_concern 'Led' 6 | include_concern 'ConfigPattern' 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/configuration_organization.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :configuration_organization do 3 | sequence(:name) { |n| "configuration_organization#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/miq_alert_status_action.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_alert_status_action do 3 | action_type 'comment' 4 | comment 'https://www.youtube.com/watch?v=dQw4w9WgXcQ' 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/vmdb_metric.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vmdb_metric do 3 | end 4 | 5 | factory :vmdb_metric_hourly, :parent => :vmdb_metric do 6 | capture_interval_name "hourly" 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /spec/factories/vmware_refresh_worker.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vmware_refresh_worker, :class => 'ManageIQ::Providers::Vmware::InfraManager::RefreshWorker' do 3 | pid { Process.pid } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/models/manageiq/providers/embedded_ansible/automation_manager/job/status_spec.rb: -------------------------------------------------------------------------------- 1 | describe ManageIQ::Providers::EmbeddedAnsible::AutomationManager::Job::Status do 2 | it_behaves_like 'ansible job status' 3 | end 4 | -------------------------------------------------------------------------------- /app/models/category.rb: -------------------------------------------------------------------------------- 1 | class Category < Classification 2 | default_scope { where(:parent_id => 0) } 3 | 4 | def tags 5 | Tag.joins(:classification).where(:classifications => {:parent_id => id}) 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_automation_manager/inventory_root_group.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAutomationManager::InventoryRootGroup < ManageIQ::Providers::AutomationManager::InventoryRootGroup 2 | end 3 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/external_automation_manager/inventory_root_group.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::ExternalAutomationManager::InventoryRootGroup < ManageIQ::Providers::AutomationManager::InventoryRootGroup 2 | end 3 | -------------------------------------------------------------------------------- /app/models/miq_smart_proxy_worker.rb: -------------------------------------------------------------------------------- 1 | class MiqSmartProxyWorker < MiqQueueWorkerBase 2 | require_nested :Runner 3 | 4 | self.required_roles = ["smartproxy"] 5 | self.default_queue_name = "smartproxy" 6 | end 7 | -------------------------------------------------------------------------------- /app/models/orchestration_template/orchestration_parameter_pattern.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationTemplate 2 | class OrchestrationParameterPattern < OrchestrationParameterConstraint 3 | attr_accessor :pattern 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /lib/extensions/ar_number_of.rb: -------------------------------------------------------------------------------- 1 | module ActiveRecord 2 | class Base 3 | def number_of(assoc) 4 | @number_of ||= {} 5 | @number_of[assoc.to_sym] ||= send(assoc).try!(:size) || 0 6 | end 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/lib/manageiq/providers/%provider_name%/version.rb: -------------------------------------------------------------------------------- 1 | module ManageIQ 2 | module Providers 3 | module <%= class_name %> 4 | VERSION = '0.1.0'.freeze 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/storage_file.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :storage_file do 3 | sequence(:name) { |n| "path/to/file#{seq_padded_for_sorting(n)}/file#{n}.log" } 4 | vm_or_template_id 1000 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/template_microsoft.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory(:template_microsoft, :class => "ManageIQ::Providers::Microsoft::InfraManager::Template", :parent => :template_infra) { vendor "microsoft" } 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_automation_manager/orchestration_stack.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAutomationManager::OrchestrationStack < 2 | ManageIQ::Providers::AutomationManager::OrchestrationStack 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/external_automation_manager/orchestration_stack.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::ExternalAutomationManager::OrchestrationStack < 2 | ManageIQ::Providers::AutomationManager::OrchestrationStack 3 | end 4 | -------------------------------------------------------------------------------- /app/models/miq_host_provision/post_install_callback.rb: -------------------------------------------------------------------------------- 1 | module MiqHostProvision::PostInstallCallback 2 | extend ActiveSupport::Concern 3 | 4 | def provision_completed 5 | signal :post_install_callback 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/network_port_security_group.rb: -------------------------------------------------------------------------------- 1 | class NetworkPortSecurityGroup < ApplicationRecord 2 | self.table_name = "network_ports_security_groups" 3 | 4 | belongs_to :network_port 5 | belongs_to :security_group 6 | end 7 | -------------------------------------------------------------------------------- /app/models/storage_performance.rb: -------------------------------------------------------------------------------- 1 | class StoragePerformance < MetricRollup 2 | default_scope { where("resource_type = 'Storage' and resource_id IS NOT NULL") } 3 | 4 | belongs_to :storage, :foreign_key => :resource_id 5 | end 6 | -------------------------------------------------------------------------------- /db/fixtures/pxe_image_types.yml: -------------------------------------------------------------------------------- 1 | --- 2 | - :name: CentOS-6 3 | :provision_type: 4 | - :name: ESX 5 | :provision_type: host 6 | - :name: RHEL-6 7 | :provision_type: 8 | - :name: Windows 9 | :provision_type: vm 10 | -------------------------------------------------------------------------------- /spec/factories/cloud_object.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :cloud_object_store_container, :class => "CloudObjectStoreContainer" 3 | 4 | factory :cloud_object_store_object, :class => "CloudObjectStoreObject" 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/cloud_service.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :cloud_service do 3 | sequence(:executable_name) { |n| "cloud_service_#{seq_padded_for_sorting(n)}" } 4 | scheduling_disabled false 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/miq_event_definition.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_event_definition do 3 | sequence(:name) { |num| "event_definition_#{num}" } 4 | description "Test event_definition" 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /app/models/configuration_script_payload.rb: -------------------------------------------------------------------------------- 1 | class ConfigurationScriptPayload < ConfigurationScriptBase 2 | belongs_to :configuration_script_source 3 | 4 | def self.base_model 5 | ConfigurationScriptPayload 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/customization_template_cloud_init.rb: -------------------------------------------------------------------------------- 1 | class CustomizationTemplateCloudInit < CustomizationTemplate 2 | DEFAULT_FILENAME = "user-data.txt".freeze 3 | 4 | def default_filename 5 | DEFAULT_FILENAME 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_automation_manager/configuration_script.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAutomationManager::ConfigurationScript < 2 | ManageIQ::Providers::AutomationManager::ConfigurationScript 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/external_automation_manager/configuration_script.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::ExternalAutomationManager::ConfigurationScript < 2 | ManageIQ::Providers::AutomationManager::ConfigurationScript 3 | end 4 | -------------------------------------------------------------------------------- /app/models/orchestration_template/orchestration_parameter_custom.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationTemplate 2 | class OrchestrationParameterCustom < OrchestrationParameterConstraint 3 | attr_accessor :custom_constraint 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/objects/43/0ff1dcee43d2e8a12c3ba36f5ff20e46136152: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ailisp/manageiq/master/spec/fixtures/git_repos/branch_and_tag.git/objects/43/0ff1dcee43d2e8a12c3ba36f5ff20e46136152 -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/objects/44/f84e202a8eb9d8d35fc183ae8637db3b003aa8: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ailisp/manageiq/master/spec/fixtures/git_repos/branch_and_tag.git/objects/44/f84e202a8eb9d8d35fc183ae8637db3b003aa8 -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/objects/78/3878cb3ed5964c75767141176c80f7d528abb5: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ailisp/manageiq/master/spec/fixtures/git_repos/branch_and_tag.git/objects/78/3878cb3ed5964c75767141176c80f7d528abb5 -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/objects/95/99fdeb034597d90d72d2f58396dee096885b79: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ailisp/manageiq/master/spec/fixtures/git_repos/branch_and_tag.git/objects/95/99fdeb034597d90d72d2f58396dee096885b79 -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/objects/ae/fde3a01f6e10d72fd4899ce14c8b2654d3eb45: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ailisp/manageiq/master/spec/fixtures/git_repos/branch_and_tag.git/objects/ae/fde3a01f6e10d72fd4899ce14c8b2654d3eb45 -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/objects/e3/16f7d7548ea8f874c872ff3be04f4e9849833b: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ailisp/manageiq/master/spec/fixtures/git_repos/branch_and_tag.git/objects/e3/16f7d7548ea8f874c872ff3be04f4e9849833b -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ailisp/manageiq/master/spec/fixtures/git_repos/branch_and_tag.git/objects/e6/9de29bb2d1d6434b8b29ae775ad8c2e48c5391 -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/objects/fd/b4bc8c22f4b3ca8279c2e1eb92670893473d05: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ailisp/manageiq/master/spec/fixtures/git_repos/branch_and_tag.git/objects/fd/b4bc8c22f4b3ca8279c2e1eb92670893473d05 -------------------------------------------------------------------------------- /tools/pg_inspector/error.rb: -------------------------------------------------------------------------------- 1 | module PgInspector 2 | module Error 3 | class PgInspectorError < RuntimeError 4 | end 5 | 6 | class ApplicationNameIncompleteError < PgInspectorError 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /.rubocop.yml: -------------------------------------------------------------------------------- 1 | inherit_from: 2 | - https://raw.githubusercontent.com/ManageIQ/guides/master/.rubocop_base.yml 3 | # put all local rubocop config into .rubocop_local.yml as it will be loaded by .rubocop_cc.yml as well 4 | - .rubocop_local.yml 5 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/storage_manager/cinder_manager/refresh_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::StorageManager::CinderManager::RefreshWorker::Runner < 2 | ManageIQ::Providers::BaseManager::RefreshWorker::Runner 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/storage_manager/swift_manager/refresh_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::StorageManager::SwiftManager::RefreshWorker::Runner < 2 | ManageIQ::Providers::BaseManager::RefreshWorker::Runner 3 | end 4 | -------------------------------------------------------------------------------- /app/models/miq_provision/helper.rb: -------------------------------------------------------------------------------- 1 | module MiqProvision::Helper 2 | def hostname_cleanup(name) 3 | hostname_length = (source.platform == 'linux') ? 63 : 15 4 | name.strip.gsub(/ +|_+/, "-")[0, hostname_length] 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /app/models/orchestration_template/orchestration_parameter_allowed_dynamic.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationTemplate 2 | class OrchestrationParameterAllowedDynamic < OrchestrationParameterConstraint 3 | attr_accessor :fqname 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /config/initializers/nokogiri_as_xmlmini_backend.rb: -------------------------------------------------------------------------------- 1 | # http://rubyglasses.blogspot.com/2009/07/40-speedup-using-nokogiri.html 2 | # Speeds up Hash#to_xml and Hash.from_xml over rexml backend. 3 | ActiveSupport::XmlMini.backend = :Nokogiri 4 | -------------------------------------------------------------------------------- /public/robots.txt: -------------------------------------------------------------------------------- 1 | # See http://www.robotstxt.org/wc/norobots.html for documentation on how to use the robots.txt file 2 | # 3 | # To ban all spiders from the entire site uncomment the next two lines: 4 | # User-Agent: * 5 | # Disallow: / 6 | -------------------------------------------------------------------------------- /spec/factories/vm_redhat.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_redhat, :class => "ManageIQ::Providers::Redhat::InfraManager::Vm", :parent => :vm_infra do 3 | vendor "redhat" 4 | raw_power_state "up" 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /.yamllint: -------------------------------------------------------------------------------- 1 | --- 2 | ignore: | 3 | /locale/** 4 | /spec/tools/openstack_data/** 5 | /vendor/** 6 | 7 | extends: relaxed 8 | 9 | rules: 10 | indentation: 11 | indent-sequences: false 12 | line-length: 13 | max: 1000 14 | -------------------------------------------------------------------------------- /app/models/computer_system.rb: -------------------------------------------------------------------------------- 1 | class ComputerSystem < ApplicationRecord 2 | belongs_to :managed_entity, :polymorphic => true 3 | 4 | has_one :operating_system, :dependent => :destroy 5 | has_one :hardware, :dependent => :destroy 6 | end 7 | -------------------------------------------------------------------------------- /app/models/ems_cluster_performance.rb: -------------------------------------------------------------------------------- 1 | class EmsClusterPerformance < MetricRollup 2 | default_scope { where("resource_type = 'EmsCluster' and resource_id IS NOT NULL") } 3 | 4 | belongs_to :ems_cluster, :foreign_key => :resource_id 5 | end 6 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/event_catcher.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::EventCatcher < ManageIQ::Providers::BaseManager::EventCatcher 2 | require_nested :Runner 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/refresh_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::RefreshWorker::Runner < ManageIQ::Providers::BaseManager::RefreshWorker::Runner 2 | end 3 | -------------------------------------------------------------------------------- /db/fixtures/tools/create_pxe_image_types_fixture.rb: -------------------------------------------------------------------------------- 1 | recs = PxeImageType.order("LOWER(name)").collect { |r| r.attributes.except("id").symbolize_keys } 2 | File.open(PxeImageType.seed_file_name, "w") do |f| 3 | f.write(recs.to_yaml) 4 | end 5 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/config/initializers/gettext.rb: -------------------------------------------------------------------------------- 1 | Vmdb::Gettext::Domains.add_domain( 2 | 'ManageIQ_Providers_<%= class_name %>', 3 | ManageIQ::Providers::<%= class_name %>::Engine.root.join('locale').to_s, 4 | :po 5 | ) 6 | -------------------------------------------------------------------------------- /locale/zh_CN.yml: -------------------------------------------------------------------------------- 1 | zh-CN: 2 | product: 3 | name: ManageIQ 4 | name_full: ManageIQ 5 | copyright: "Copyright (c) 2017 ManageIQ。由红帽赞助。" 6 | support_website: "http://www.manageiq.org" 7 | support_website_text: "ManageIQ.org" 8 | -------------------------------------------------------------------------------- /spec/factories/miq_scsi_lun.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_scsi_lun do 3 | sequence(:device_name) { |n| "miq_scsi_lun_#{n}" } 4 | sequence(:lun) { 0 } 5 | sequence(:device_type) { 'cdrom' } 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/container_limit.rb: -------------------------------------------------------------------------------- 1 | class ContainerLimit < ApplicationRecord 2 | belongs_to :ext_management_system, :foreign_key => "ems_id" 3 | belongs_to :container_project 4 | 5 | has_many :container_limit_items, :dependent => :destroy 6 | end 7 | -------------------------------------------------------------------------------- /app/models/container_quota.rb: -------------------------------------------------------------------------------- 1 | class ContainerQuota < ApplicationRecord 2 | belongs_to :ext_management_system, :foreign_key => "ems_id" 3 | belongs_to :container_project 4 | 5 | has_many :container_quota_items, :dependent => :destroy 6 | end 7 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/base_manager/metrics_capture.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::BaseManager::MetricsCapture 2 | include Vmdb::Logging 3 | 4 | attr_reader :target 5 | def initialize(target) 6 | @target = target 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/cloud_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::CloudCredential < 2 | ManageIQ::Providers::EmbeddedAnsible::AutomationManager::Credential 3 | end 4 | -------------------------------------------------------------------------------- /app/models/container_volume.rb: -------------------------------------------------------------------------------- 1 | class ContainerVolume < ApplicationRecord 2 | include CustomActionsMixin 3 | acts_as_miq_taggable 4 | belongs_to :parent, :polymorphic => true 5 | belongs_to :persistent_volume_claim, :dependent => :destroy 6 | end 7 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_automation_manager/configuration_script_payload.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAutomationManager::ConfigurationScriptPayload < 2 | ManageIQ::Providers::AutomationManager::ConfigurationScriptPayload 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_automation_manager/configuration_script_source.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAutomationManager::ConfigurationScriptSource < 2 | ManageIQ::Providers::AutomationManager::ConfigurationScriptSource 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/external_automation_manager/configuration_script_payload.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::ExternalAutomationManager::ConfigurationScriptPayload < 2 | ManageIQ::Providers::AutomationManager::ConfigurationScriptPayload 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/external_automation_manager/configuration_script_source.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::ExternalAutomationManager::ConfigurationScriptSource < 2 | ManageIQ::Providers::AutomationManager::ConfigurationScriptSource 3 | end 4 | -------------------------------------------------------------------------------- /app/models/miq_priority_worker.rb: -------------------------------------------------------------------------------- 1 | class MiqPriorityWorker < MiqQueueWorkerBase 2 | require_nested :Runner 3 | 4 | self.default_queue_name = "generic" 5 | 6 | def self.queue_priority 7 | MiqQueue::HIGH_PRIORITY 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/orchestration_template/orchestration_parameter_range.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationTemplate 2 | class OrchestrationParameterRange < OrchestrationParameterConstraint 3 | attr_accessor :min_value 4 | attr_accessor :max_value 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /app/models/settings_change.rb: -------------------------------------------------------------------------------- 1 | class SettingsChange < ApplicationRecord 2 | serialize :value 3 | 4 | belongs_to :resource, :polymorphic => true 5 | 6 | def key_path 7 | key.to_s.split("/").drop(1).collect(&:to_sym) 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/vm_or_template/operations/smart_state.rb: -------------------------------------------------------------------------------- 1 | class VmOrTemplate 2 | module Operations 3 | module SmartState 4 | def validate_scan 5 | {:available => true, :message => nil} 6 | end 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/vmdb_database_metric.rb: -------------------------------------------------------------------------------- 1 | class VmdbDatabaseMetric < ApplicationRecord 2 | belongs_to :vmdb_database 3 | 4 | VmdbMetric # Eager load VmdbMetric class to allow access to VmdbMetric::Purging 5 | include_concern 'VmdbMetric::Purging' 6 | end 7 | -------------------------------------------------------------------------------- /config/initializers/mime_types.rb: -------------------------------------------------------------------------------- 1 | # Be sure to restart your server when you modify this file. 2 | 3 | # Add new mime types for use in respond_to blocks: 4 | # Mime::Type.register "text/richtext", :rtf 5 | # Mime::Type.register_alias "text/html", :iphone 6 | -------------------------------------------------------------------------------- /lib/extensions/ar_paginate.rb: -------------------------------------------------------------------------------- 1 | module ActiveRecord 2 | class Base 3 | # 4 | # Used by the REST API 5 | # 6 | def self.paginate(req_offset, req_limit) 7 | offset(req_offset).limit(req_limit) 8 | end 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /lib/resource_feeder/README: -------------------------------------------------------------------------------- 1 | ResourceFeeder 2 | ============== 3 | 4 | Simple feeds for resources 5 | 6 | NOTE: This plugin depends on the latest version of simply_helpful, available here: 7 | http://dev.rubyonrails.org/svn/rails/plugins/simply_helpful/ 8 | -------------------------------------------------------------------------------- /public/proxy_pages/invalid_sso_credentials.js: -------------------------------------------------------------------------------- 1 | throw "error"; 2 | $('#invalid_sso_credentials_flash').click(function() { 3 | $(this).hide(); 4 | }); 5 | $('#invalid_sso_credentials_flash').show(); 6 | miqSparkle(false); 7 | miqEnableLoginFields(true); 8 | -------------------------------------------------------------------------------- /spec/factories/miq_scsi_target.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_scsi_target do 3 | sequence(:iscsi_name) { |n| "miq_scsi_target_#{n}" } 4 | sequence(:target) { 5 } 5 | sequence(:miq_scsi_luns) { [] } 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/orchestration_template/orchestration_parameter_length.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationTemplate 2 | class OrchestrationParameterLength < OrchestrationParameterConstraint 3 | attr_accessor :min_length 4 | attr_accessor :max_length 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /locale/es.yml: -------------------------------------------------------------------------------- 1 | es: 2 | product: 3 | name: ManageIQ 4 | name_full: ManageIQ 5 | copyright: "Copyright (c) 2017 ManageIQ. Sponsored by Red Hat Inc." 6 | support_website: "http://www.manageiq.org" 7 | support_website_text: "ManageIQ.org" 8 | -------------------------------------------------------------------------------- /locale/fr.yml: -------------------------------------------------------------------------------- 1 | fr: 2 | product: 3 | name: ManageIQ 4 | name_full: ManageIQ 5 | copyright: "Copyright (c) 2017 ManageIQ. Sponsored by Red Hat Inc." 6 | support_website: "http://www.manageiq.org" 7 | support_website_text: "ManageIQ.org" 8 | -------------------------------------------------------------------------------- /app/models/authentication_ldap.rb: -------------------------------------------------------------------------------- 1 | class AuthenticationLdap < Authentication 2 | def assign_values(options) 3 | hash = {} 4 | options.each do |key, val| 5 | hash["ldap_" + key.to_s] = val 6 | end 7 | super(hash) 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/manager_refresh/inventory/parser.rb: -------------------------------------------------------------------------------- 1 | class ManagerRefresh::Inventory::Parser 2 | attr_accessor :collector 3 | attr_accessor :persister 4 | 5 | def parse 6 | raise NotImplementedError, _("must be implemented in a subclass") 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /app/models/miq_report/formatters/html.rb: -------------------------------------------------------------------------------- 1 | module MiqReport::Formatters::Html 2 | def to_html 3 | ReportFormatter::ReportRenderer.render(:html) do |e| 4 | e.options.mri = self # set the MIQ_Report instance in the formatter 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/chargeback_rate_detail_currency.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :chargeback_rate_detail_currency do 3 | code "EUR" 4 | name "Euro" 5 | full_name "Euro" 6 | symbol "€" 7 | unicode_hex "8364" 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/compute_node.rb: -------------------------------------------------------------------------------- 1 | class ComputeNode < ApplicationRecord 2 | include NewWithTypeStiMixin 3 | 4 | acts_as_miq_taggable 5 | 6 | belongs_to :ext_management_system, :foreign_key => :ems_id, :class_name => "ManageIQ::Providers::PhysicalInfraManager" 7 | end 8 | -------------------------------------------------------------------------------- /app/models/miq_provision/description.rb: -------------------------------------------------------------------------------- 1 | module MiqProvision::Description 2 | def set_description(vm, description) 3 | _log.info("Setting #{vm.class.base_model.name} description to #{description.inspect}") 4 | vm.description = description 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /app/models/miq_provision/iso.rb: -------------------------------------------------------------------------------- 1 | module MiqProvision::Iso 2 | def iso_image 3 | @iso_image ||= begin 4 | klass, id = get_option(:iso_image_id).to_s.split('::') 5 | id.blank? ? nil : klass.constantize.find_by(:id => id) 6 | end 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /app/models/orchestration_template/orchestration_parameter_allowed.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationTemplate 2 | class OrchestrationParameterAllowed < OrchestrationParameterConstraint 3 | attr_accessor :allowed_values 4 | attr_accessor :allow_multiple 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/miq_database.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_database do 3 | session_secret_token { SecureRandom.hex(64) } 4 | csrf_secret_token { SecureRandom.hex(64) } 5 | update_repo_name "cf-me-5.2-for-rhel-6-rpms" 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/miq_widget_set.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_widget_set do 3 | sequence(:name) { |n| "widget_set_#{seq_padded_for_sorting(n)}" } 4 | sequence(:description) { |n| "widget_set_#{seq_padded_for_sorting(n)}" } 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/pxe_server.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :pxe_server do 3 | sequence(:name) { |n| "pxe_server_#{seq_padded_for_sorting(n)}" } 4 | sequence(:uri) { |n| "http://test.example.com/pxe_server_#{seq_padded_for_sorting(n)}" } 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/template_vmware_cloud.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :template_vmware_cloud, 3 | :class => "ManageIQ::Providers::Vmware::CloudManager::Template", 4 | :parent => :template_cloud do 5 | vendor "vmware" 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/models/manageiq/providers/embedded_ansible/automation_manager/configuration_script_source_spec.rb: -------------------------------------------------------------------------------- 1 | describe ManageIQ::Providers::EmbeddedAnsible::AutomationManager::ConfigurationScriptSource do 2 | it_behaves_like 'ansible configuration_script_source' 3 | end 4 | -------------------------------------------------------------------------------- /app/models/container_performance.rb: -------------------------------------------------------------------------------- 1 | class ContainerPerformance < MetricRollup 2 | default_scope { where("resource_type = 'Container' and resource_id IS NOT NULL") } 3 | 4 | belongs_to :container_node, :foreign_key => :resource_id, :class_name => Container.name 5 | end 6 | -------------------------------------------------------------------------------- /app/models/miq_report/formatters.rb: -------------------------------------------------------------------------------- 1 | module MiqReport::Formatters 2 | extend ActiveSupport::Concern 3 | 4 | include_concern 'Csv' 5 | include_concern 'Graph' 6 | include_concern 'Html' 7 | include_concern 'Text' 8 | include_concern 'Timeline' 9 | end 10 | -------------------------------------------------------------------------------- /app/models/scan_history.rb: -------------------------------------------------------------------------------- 1 | class ScanHistory < ApplicationRecord 2 | belongs_to :vm_or_template 3 | belongs_to :vm, :foreign_key => :vm_or_template_id 4 | belongs_to :miq_template, :foreign_key => :vm_or_template_id 5 | 6 | include FilterableMixin 7 | end 8 | -------------------------------------------------------------------------------- /app/models/serializer.rb: -------------------------------------------------------------------------------- 1 | class Serializer 2 | private 3 | 4 | def included_attributes(attributes, all_attributes = false) 5 | return attributes if all_attributes 6 | attributes.reject { |key, _| self.class::EXCLUDED_ATTRIBUTES.include?(key) } 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /config/initializers/session_patch.rb: -------------------------------------------------------------------------------- 1 | class ActionDispatch::Request::Session 2 | include MoreCoreExtensions::Shared::Nested 3 | end 4 | 5 | class ActionController::TestSession < Rack::Session::Abstract::SessionHash 6 | include MoreCoreExtensions::Shared::Nested 7 | end 8 | -------------------------------------------------------------------------------- /lib/extensions/ar_base_model.rb: -------------------------------------------------------------------------------- 1 | module ActiveRecord 2 | class Base 3 | class << self 4 | alias_method :base_model, :base_class 5 | 6 | def model_suffix 7 | name[base_model.name.length..-1] 8 | end 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/.rubocop.yml: -------------------------------------------------------------------------------- 1 | inherit_from: 2 | - https://raw.githubusercontent.com/ManageIQ/guides/master/.rubocop_base.yml 3 | # put all local rubocop config into .rubocop_local.yml as it will be loaded by .rubocop_cc.yml as well 4 | - .rubocop_local.yml 5 | -------------------------------------------------------------------------------- /spec/factories/categories.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory(:category) do 3 | sequence(:name) { |n| "category_#{seq_padded_for_sorting(n)}" } 4 | sequence(:description) { |n| "category #{seq_padded_for_sorting(n)}" } 5 | parent_id 0 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/windows_image.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :windows_image do 3 | sequence(:name) { |n| "windows_image_#{seq_padded_for_sorting(n)}" } 4 | sequence(:description) { |n| "windows_desc_#{seq_padded_for_sorting(n)}" } 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/shared/README.md: -------------------------------------------------------------------------------- 1 | # Shared Example Groups 2 | 3 | Note that these shared example groups may be utilized outside of the core 4 | project; for example, provider gems utilize and run `:floating_ip` for their 5 | specific provider. Edit and remove these files with caution. 6 | -------------------------------------------------------------------------------- /app/models/miq_report/formatters/timeline.rb: -------------------------------------------------------------------------------- 1 | module MiqReport::Formatters::Timeline 2 | def to_timeline 3 | ReportFormatter::ReportRenderer.render(:timeline) do |e| 4 | e.options.mri = self # set the MIQ_Report instance in the formatter 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/service_order.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory(:service_order) do 3 | name "service order" 4 | state "ordered" 5 | 6 | factory(:shopping_cart) do 7 | name "shopping cart" 8 | state "cart" 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/ext_management_system_performance.rb: -------------------------------------------------------------------------------- 1 | class ExtManagementSystemPerformance < MetricRollup 2 | default_scope { where("resource_type = 'ExtManagementSystem' and resource_id IS NOT NULL") } 3 | 4 | belongs_to :ext_management_system, :foreign_key => :resource_id 5 | end 6 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/job/status.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::Job::Status < ::OrchestrationStack::Status 2 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::Job::Status 3 | end 4 | -------------------------------------------------------------------------------- /config/initializers/active_metrics.rb: -------------------------------------------------------------------------------- 1 | # Note: The legacy Postgresql adapter ignores everything except the adapter name here, just stealing the current ActiveRecord connection. 2 | ActiveMetrics::Base.establish_connection(:adapter => "miq_postgres", :database => "manageiq_metrics") 3 | -------------------------------------------------------------------------------- /lib/extensions/ar_href_slug.rb: -------------------------------------------------------------------------------- 1 | module ArHrefSlug 2 | extend ActiveSupport::Concern 3 | 4 | included do 5 | virtual_column :href_slug, :type => :string 6 | 7 | def href_slug 8 | Api::Utils.build_href_slug(self.class, id) 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /lib/pdf_generator/null_pdf_generator.rb: -------------------------------------------------------------------------------- 1 | class NullPdfGenerator < PdfGenerator 2 | def self.available? 3 | false 4 | end 5 | 6 | def pdf_from_string(_html_string, _stylesheet) 7 | raise NotImplementedError, "pdf generation is not available" 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /spec/factories/system_console.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory(:system_console) do 3 | host_name 'manageiq.org' 4 | port '80' 5 | ssl false 6 | protocol :vnc 7 | secret SecureRandom.base64[0, 8] 8 | vm nil 9 | user nil 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /spec/fixtures/git_repos/branch_and_tag.git/packed-refs: -------------------------------------------------------------------------------- 1 | # pack-refs with: peeled fully-peeled 2 | 783878cb3ed5964c75767141176c80f7d528abb5 refs/heads/branch1 3 | e316f7d7548ea8f874c872ff3be04f4e9849833b refs/heads/branch2 4 | 44f84e202a8eb9d8d35fc183ae8637db3b003aa8 refs/heads/master 5 | -------------------------------------------------------------------------------- /spec/models/customization_template_cloud_init_spec.rb: -------------------------------------------------------------------------------- 1 | describe CustomizationTemplateCloudInit do 2 | context "#default_filename" do 3 | it "should be user-data.txt" do 4 | expect(described_class.new.default_filename).to eq('user-data.txt') 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/models/rss_feed/import_export_spec.rb: -------------------------------------------------------------------------------- 1 | describe RssFeed::ImportExport do 2 | it "#export_to_array" do 3 | expect(FactoryGirl.create(:rss_feed, :title => "Latest things!!!") 4 | .export_to_array.first["RssFeed"]["title"]).to eq("Latest things!!!") 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /app/models/miq_provision/genealogy.rb: -------------------------------------------------------------------------------- 1 | module MiqProvision::Genealogy 2 | def set_genealogy(child, parent) 3 | _log.info("Setting Genealogy Parent to #{parent.class.base_model.name} Name=#{parent.name}, ID=#{parent.id}") 4 | parent.add_genealogy_child(child) 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/template_azure.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :template_azure, :class => "ManageIQ::Providers::Azure::CloudManager::Template", :parent => :template_cloud do 3 | location { |x| "#{x.name}/#{x.name}.img.manifest.xml" } 4 | vendor "azure" 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /tools/rest_api.rb: -------------------------------------------------------------------------------- 1 | #! /usr/bin/env ruby 2 | Dir.chdir(File.join(__dir__, "..")) { require 'bundler/setup' } 3 | require 'pathname' 4 | 5 | gem_dir = Pathname.new(Bundler.locked_gems.specs.select { |g| g.name == "manageiq-api" }.first.gem_dir) 6 | load gem_dir.join('exe', 'manageiq-api') 7 | -------------------------------------------------------------------------------- /app/models/container_node_performance.rb: -------------------------------------------------------------------------------- 1 | class ContainerNodePerformance < MetricRollup 2 | default_scope { where("resource_type = 'ContainerNode' and resource_id IS NOT NULL") } 3 | 4 | belongs_to :container_node, :foreign_key => :resource_id, :class_name => ContainerNode.name 5 | end 6 | -------------------------------------------------------------------------------- /app/models/host_performance.rb: -------------------------------------------------------------------------------- 1 | class HostPerformance < MetricRollup 2 | default_scope { where("resource_type = 'Host' and resource_id IS NOT NULL") } 3 | 4 | belongs_to :ems_cluster, :foreign_key => :parent_ems_cluster_id 5 | belongs_to :host, :foreign_key => :resource_id 6 | end 7 | -------------------------------------------------------------------------------- /app/models/miq_host_provision/tagging.rb: -------------------------------------------------------------------------------- 1 | module MiqHostProvision::Tagging 2 | def apply_tags(host) 3 | tags do |tag, cat| 4 | _log.info("Tagging [#{host.name}], Category: [#{cat}], Tag: #{tag}") 5 | Classification.classify(host, cat.to_s, tag) 6 | end 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /spec/factories/miq_widget.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_widget do 3 | sequence(:title) { |n| "widget_#{seq_padded_for_sorting(n)}" } 4 | sequence(:description) { |n| "widget_#{seq_padded_for_sorting(n)}" } 5 | content_type "report" 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/lib/extensions/ar_column_names_spec.rb: -------------------------------------------------------------------------------- 1 | describe "ar_column_names extension" do 2 | context "With an empty test class" do 3 | it "should have the correct column names symbols" do 4 | expect(SchemaMigration.column_names_symbols).to eq([:version]) 5 | end 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/models/pxe_data/ipxe/mac/00-50-56-91-79-d5: -------------------------------------------------------------------------------- 1 | #!ipxe 2 | kernel http://192.168.252.60/ipxe/rhel6.2-desktop/vmlinuz ramdisk_size=10000 ks=http://192.168.252.60/pxelinux.cfg/rhel6.2-host.ks.cfg ksdevice=00:50:56:91:79:d5 3 | initrd http://192.168.252.60/ipxe/rhel6.2-desktop/initrd.img 4 | boot 5 | -------------------------------------------------------------------------------- /app/models/container_group_performance.rb: -------------------------------------------------------------------------------- 1 | class ContainerGroupPerformance < MetricRollup 2 | default_scope { where("resource_type = 'ContainerGroup' and resource_id IS NOT NULL") } 3 | 4 | belongs_to :container_group, :foreign_key => :resource_id, :class_name => ContainerGroup.name 5 | end 6 | -------------------------------------------------------------------------------- /app/models/container_template_parameter.rb: -------------------------------------------------------------------------------- 1 | class ContainerTemplateParameter < ApplicationRecord 2 | include CustomAttributeMixin 3 | belongs_to :container_template 4 | 5 | def instantiation_attributes 6 | attributes.slice("name", "value", "generate", "from", "required") 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/base_manager/metrics_collector_worker/runner.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::BaseManager::MetricsCollectorWorker::Runner < ::MiqQueueWorkerBase::Runner 2 | self.delay_startup_for_vim_broker = true # NOTE: For ems_metrics_collector role, TODO: only for VMware 3 | end 4 | -------------------------------------------------------------------------------- /tools/db_ping.rb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require File.expand_path('../config/environment', __dir__) 3 | 4 | total = 0 5 | 5.times do 6 | ping = EvmDatabase.ping 7 | puts "%.6f ms" % ping 8 | total += ping 9 | sleep 1 10 | end 11 | puts 12 | puts "Average: %.6f ms" % (total / 5) 13 | -------------------------------------------------------------------------------- /app/models/auth_userid_password.rb: -------------------------------------------------------------------------------- 1 | class AuthUseridPassword < Authentication 2 | def password=(val) 3 | @auth_changed = true if val != password 4 | super(val) 5 | end 6 | 7 | def userid=(val) 8 | @auth_changed = true if val != userid 9 | super(val) 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/container_project_performance.rb: -------------------------------------------------------------------------------- 1 | class ContainerProjectPerformance < MetricRollup 2 | default_scope { where("resource_type = 'ContainerProject' and resource_id IS NOT NULL") } 3 | 4 | belongs_to :container_node, :foreign_key => :resource_id, :class_name => ContainerProject.name 5 | end 6 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/inventory/parser/automation_manager.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::Inventory::Parser::AutomationManager < ManagerRefresh::Inventory::Parser 2 | include ManageIQ::Providers::AnsibleTower::Shared::Inventory::Parser::AutomationManager 3 | end 4 | -------------------------------------------------------------------------------- /app/models/metric.rb: -------------------------------------------------------------------------------- 1 | class Metric < ApplicationRecord 2 | BASE_COLS = ["id", "timestamp", "capture_interval_name", "resource_type", "resource_id", "resource_name", "tag_names", "parent_host_id", "parent_ems_cluster_id", "parent_ems_id", "parent_storage_id"] 3 | 4 | include Metric::Common 5 | end 6 | -------------------------------------------------------------------------------- /app/models/miq_generic_worker.rb: -------------------------------------------------------------------------------- 1 | class MiqGenericWorker < MiqQueueWorkerBase 2 | require_nested :Runner 3 | 4 | self.default_queue_name = "generic" 5 | self.check_for_minimal_role = false 6 | self.workers = -> { MiqServer.minimal_env? ? 1 : worker_settings[:count] } 7 | end 8 | -------------------------------------------------------------------------------- /app/models/miq_provision_task/tagging.rb: -------------------------------------------------------------------------------- 1 | module MiqProvisionTask::Tagging 2 | def apply_tags(inv_obj) 3 | tags do |tag, cat| 4 | _log.info("Tagging [#{inv_obj.name}], Category: [#{cat}], Tag: #{tag}") 5 | Classification.classify(inv_obj, cat.to_s, tag) 6 | end 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /app/models/rss_feed/import_export.rb: -------------------------------------------------------------------------------- 1 | module RssFeed::ImportExport 2 | extend ActiveSupport::Concern 3 | 4 | def export_to_array 5 | h = attributes 6 | ["id", "created_on", "updated_on", "yml_file_mtime"].each { |k| h.delete(k) } 7 | [self.class.to_s => h] 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /config/routes.rb: -------------------------------------------------------------------------------- 1 | Vmdb::Application.routes.draw do 2 | if Rails.env.development? && defined?(Rails::Server) 3 | logger = Logger.new(STDOUT) 4 | logger.level = Logger.const_get(::Settings.log.level_websocket.upcase) 5 | mount WebsocketServer.new(:logger => logger) => '/ws' 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/host_service_group_openstack.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :host_service_group_openstack, :class => "ManageIQ::Providers::Openstack::InfraManager::HostServiceGroup" do 3 | sequence(:name) { |n| "host_service_group_openstack_#{seq_padded_for_sorting(n)}" } 4 | end 5 | end 6 | -------------------------------------------------------------------------------- /spec/factories/miq_action.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_action do 3 | sequence(:name) { |num| "action_#{seq_padded_for_sorting(num)}" } 4 | sequence(:description) { |num| "Test Action_#{seq_padded_for_sorting(num)}" } 5 | action_type "Test" 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /spec/factories/miq_task.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :miq_task do 3 | status "Ok" 4 | state "Active" 5 | sequence(:name) { |n| "task_#{seq_padded_for_sorting(n)}" } 6 | end 7 | 8 | factory :miq_task_plain, :class => :miq_task do 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /spec/models/file_depot_ftp_anonymous_spec.rb: -------------------------------------------------------------------------------- 1 | describe FileDepotFtpAnonymous do 2 | it "should require credentials for anonymous" do 3 | expect(FileDepotFtpAnonymous.requires_credentials?).to eq true 4 | expect(FileDepotFtpAnonymous.new.login_credentials[0]).to eq "anonymous" 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/models/vmdb_metric_spec.rb: -------------------------------------------------------------------------------- 1 | describe VmdbMetric do 2 | before(:each) do 3 | EvmSpecHelper.create_guid_miq_server_zone 4 | end 5 | 6 | it "should purge" do 7 | expect do 8 | VmdbMetric.purge_daily_timer 9 | end.to change { MiqQueue.count }.by(1) 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/host_metric.rb: -------------------------------------------------------------------------------- 1 | class HostMetric < Metric 2 | default_scope { where("resource_type = 'Host' and resource_id IS NOT NULL") } 3 | 4 | belongs_to :host, :foreign_key => :resource_id 5 | belongs_to :ems_cluster, :foreign_key => :parent_ems_cluster_id 6 | end 7 | -------------------------------------------------------------------------------- /spec/factories/vmdb_table.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vmdb_table do 3 | end 4 | 5 | factory :vmdb_table_evm, :parent => :vmdb_table, :class => "VmdbTableEvm" do 6 | end 7 | 8 | factory :vmdb_table_text, :parent => :vmdb_table, :class => "VmdbTableText" do 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /tools/delete_ems_metadata_relationships.rb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require File.expand_path('../config/environment', __dir__) 3 | 4 | puts "Deleting ems_metadata Relationships..." 5 | Relationship.where(:relationship => "ems_metadata").delete_all 6 | puts "Deleting ems_metadata Relationships...Complete" 7 | -------------------------------------------------------------------------------- /app/channels/notification_channel.rb: -------------------------------------------------------------------------------- 1 | class NotificationChannel < ApplicationCable::Channel 2 | def subscribed 3 | stream_from("notifications_#{current_user.id}") if current_user 4 | end 5 | 6 | def unsubscribed 7 | # TODO: Any cleanup needed when channel is unsubscribed 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/vm_or_template/retirement_management.rb: -------------------------------------------------------------------------------- 1 | module VmOrTemplate::RetirementManagement 2 | extend ActiveSupport::Concern 3 | 4 | def retired_validated? 5 | ['off', 'never'].include?(state) 6 | end 7 | 8 | def retired_invalid_reason 9 | "has state: [#{state}]" 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/config/settings.yml: -------------------------------------------------------------------------------- 1 | --- 2 | :ems: 3 | :ems_<%= provider_name %>: 4 | :blacklisted_event_names: [] 5 | :event_handling: 6 | :event_groups: 7 | :http_proxy: 8 | :<%= provider_name %>: 9 | :host: 10 | :password: 11 | :port: 12 | :user: 13 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/lib/tasks/README.md: -------------------------------------------------------------------------------- 1 | Tasks (.rake files) in this directory will be available in the main ManageIQ app. 2 | They can be executed in the provider gem via the app: namespace 3 | 4 | bin/rails app: 5 | 6 | Task private to the provider should go into lib/tasks/tasks_private. 7 | -------------------------------------------------------------------------------- /spec/factories/notification_type.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :notification_type do 3 | sequence(:name) { |n| "notification_type_#{seq_padded_for_sorting(n)}" } 4 | sequence(:message) { |n| "message_#{seq_padded_for_sorting(n)}" } 5 | audience 'user' 6 | level "info" 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /spec/factories/vm_microsoft.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_microsoft, :class => "ManageIQ::Providers::Microsoft::InfraManager::Vm", :parent => :vm_infra do 3 | location { |x| "#{x.name}/#{x.name}.xml" } 4 | vendor "microsoft" 5 | raw_power_state "Running" 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/event_parser.rb: -------------------------------------------------------------------------------- 1 | module ManageIQ::Providers::EmbeddedAnsible::AutomationManager::EventParser 2 | extend ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::EventParser 3 | 4 | def self.source 5 | "EMBEDDEDANSIBLE" 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/inventory/collector/automation_manager.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::Inventory::Collector::AutomationManager < ManagerRefresh::Inventory::Collector 2 | include ManageIQ::Providers::AnsibleTower::Shared::Inventory::Collector::AutomationManager 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/inventory/persister/automation_manager.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::Inventory::Persister::AutomationManager < ManagerRefresh::Inventory::Persister 2 | include ManageIQ::Providers::AnsibleTower::Shared::Inventory::Persister::AutomationManager 3 | end 4 | -------------------------------------------------------------------------------- /lib/extensions/ar_types.rb: -------------------------------------------------------------------------------- 1 | require 'active_record/connection_adapters/postgresql_adapter' 2 | ActiveRecord::ConnectionAdapters::PostgreSQLAdapter.module_eval do 3 | prepend Module.new { 4 | def initialize_type_map(m) 5 | super 6 | m.alias_type('xid', 'varchar') 7 | end 8 | } 9 | end 10 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/lib/manageiq/providers/%provider_name%/engine.rb: -------------------------------------------------------------------------------- 1 | module ManageIQ 2 | module Providers 3 | module <%= class_name %> 4 | class Engine < ::Rails::Engine 5 | isolate_namespace ManageIQ::Providers::<%= class_name %> 6 | end 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /spec/initializers/as_inflections_spec.rb: -------------------------------------------------------------------------------- 1 | describe String, "inflections" do 2 | { 3 | "base" => "bases", 4 | }.each do |singular, plural| 5 | example("#pluralize") { expect(singular.pluralize).to eq(plural) } 6 | example("#singularize") { expect(plural.singularize).to eq(singular) } 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /spec/models/miq_policy_content_spec.rb: -------------------------------------------------------------------------------- 1 | describe MiqPolicyContent do 2 | context 'Empty content' do 3 | describe '#export_to_array' do 4 | subject { FactoryGirl.create(:miq_policy_content).export_to_array } 5 | it { is_expected.to match_array(['MiqPolicyContent'=>{}]) } 6 | end 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /app/models/orchestration_template/orchestration_resource.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationTemplate 2 | class OrchestrationResource 3 | attr_accessor :name 4 | attr_accessor :type 5 | 6 | def initialize(hash = {}) 7 | hash.each { |key, value| public_send("#{key}=", value) } 8 | end 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /config/initializers/yaml_autoloader.rb: -------------------------------------------------------------------------------- 1 | # Autoload Rails Models 2 | # see https://github.com/collectiveidea/delayed_job/blob/master/lib/delayed/psych_ext.rb 3 | 4 | Psych::Visitors::ToRuby.prepend Module.new { 5 | def resolve_class(klass_name) 6 | klass_name && klass_name.safe_constantize || super 7 | end 8 | } 9 | -------------------------------------------------------------------------------- /lib/content_exporter.rb: -------------------------------------------------------------------------------- 1 | module ContentExporter 2 | def self.export_to_hash(initial_hash, key, elements) 3 | hash = initial_hash.dup 4 | %w(id created_on updated_on).each { |k| hash.delete(k) } 5 | hash[key] = elements.collect { |e| e.export_to_array.first[key] unless e.nil? } 6 | hash 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /spec/models/cloud_volume_spec.rb: -------------------------------------------------------------------------------- 1 | describe CloudVolume do 2 | it ".available" do 3 | disk = FactoryGirl.create(:disk) 4 | FactoryGirl.create(:cloud_volume, :attachments => [disk]) 5 | cv2 = FactoryGirl.create(:cloud_volume) 6 | 7 | expect(described_class.available).to eq([cv2]) 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/scm_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::ScmCredential < ManageIQ::Providers::EmbeddedAnsible::AutomationManager::Credential 2 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::ScmCredential 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/inventory/parser/configuration_script_source.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::Inventory::Parser::ConfigurationScriptSource < ManagerRefresh::Inventory::Parser 2 | include ManageIQ::Providers::AnsibleTower::Shared::Inventory::Parser::ConfigurationScriptSource 3 | end 4 | -------------------------------------------------------------------------------- /app/models/orchestration_template/orchestration_parameter_constraint.rb: -------------------------------------------------------------------------------- 1 | class OrchestrationTemplate 2 | class OrchestrationParameterConstraint 3 | attr_accessor :description 4 | 5 | def initialize(hash = {}) 6 | hash.each { |key, value| public_send("#{key}=", value) } 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/resource_group.rb: -------------------------------------------------------------------------------- 1 | class ResourceGroup < ApplicationRecord 2 | alias_attribute :images, :templates 3 | 4 | has_many :vm_or_templates 5 | 6 | # Rely on default scopes to get expected information 7 | has_many :vms, :class_name => 'Vm' 8 | has_many :templates, :class_name => 'MiqTemplate' 9 | end 10 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/.gitignore: -------------------------------------------------------------------------------- 1 | .rubocop-* 2 | /.bundle/ 3 | /.yardoc 4 | /Gemfile.lock 5 | /_yardoc/ 6 | /coverage/ 7 | /doc/ 8 | /pkg/ 9 | /spec/reports/ 10 | /tmp/ 11 | 12 | /config/settings.local.yml 13 | /config/settings/*.local.yml 14 | /config/environments/*.local.yml 15 | 16 | /spec/manageiq 17 | -------------------------------------------------------------------------------- /spec/lib/vmdb/fast_gettext_helper_spec.rb: -------------------------------------------------------------------------------- 1 | describe Vmdb::FastGettextHelper do 2 | describe ".register_locales" do 3 | it "registers locales across all threads" do 4 | Thread.new do 5 | I18n.locale = 'en-US' 6 | expect(I18n.locale).to eq(:en) 7 | end.join 8 | end 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /app/models/cloud_object_store_object/operations.rb: -------------------------------------------------------------------------------- 1 | module CloudObjectStoreObject::Operations 2 | extend ActiveSupport::Concern 3 | 4 | def delete_cloud_object_store_object 5 | raw_delete 6 | end 7 | 8 | def raw_delete 9 | raise NotImplementedError, _("must be implemented in subclass") 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/customization_script.rb: -------------------------------------------------------------------------------- 1 | class CustomizationScript < ApplicationRecord 2 | include NewWithTypeStiMixin 3 | include DeprecationMixin 4 | 5 | acts_as_miq_taggable 6 | deprecate_belongs_to(:provisioning_manager, :ext_management_system) 7 | belongs_to(:ext_management_system, :foreign_key => "manager_id") 8 | end 9 | -------------------------------------------------------------------------------- /lib/extensions/ar_base.rb: -------------------------------------------------------------------------------- 1 | module ActiveRecord 2 | class Base 3 | include Vmdb::Logging 4 | 5 | # Truncates the table. 6 | # 7 | # ==== Example 8 | # 9 | # Post.truncate 10 | def self.truncate 11 | connection.truncate(table_name, "#{name} Truncate") 12 | end 13 | end 14 | end 15 | -------------------------------------------------------------------------------- /lib/generators/provider/templates/lib/tasks/%provider_name%.rake: -------------------------------------------------------------------------------- 1 | #namespace :manageiq do 2 | # namespace :providers do 3 | # namespace :<%= provider_name %> do 4 | # desc "Explaining what the task does" 5 | # task :your_task do 6 | # # Task goes here 7 | # end 8 | # end 9 | # end 10 | #end 11 | -------------------------------------------------------------------------------- /tools/miqldap_to_sssd/sssd_conf/pam.rb: -------------------------------------------------------------------------------- 1 | require 'sssd_conf/common' 2 | 3 | module MiqLdapToSssd 4 | class Pam < Common 5 | def initialize(initial_settings) 6 | super(%w(pam_app_services), initial_settings) 7 | end 8 | 9 | def pam_app_services 10 | "httpd-auth" 11 | end 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /app/models/middleware_domain.rb: -------------------------------------------------------------------------------- 1 | class MiddlewareDomain < ApplicationRecord 2 | include NewWithTypeStiMixin 3 | 4 | belongs_to :ext_management_system, :foreign_key => "ems_id" 5 | has_many :middleware_server_groups, :foreign_key => "domain_id", :dependent => :destroy 6 | serialize :properties 7 | acts_as_miq_taggable 8 | end 9 | -------------------------------------------------------------------------------- /app/models/miq_web_service_worker.rb: -------------------------------------------------------------------------------- 1 | class MiqWebServiceWorker < MiqWorker 2 | require_nested :Runner 3 | 4 | self.required_roles = ['web_services'] 5 | 6 | STARTING_PORT = 4000 7 | 8 | def friendly_name 9 | @friendly_name ||= "Web Services Worker" 10 | end 11 | 12 | include MiqWebServerWorkerMixin 13 | end 14 | -------------------------------------------------------------------------------- /spec/factories/custom_attribute.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :custom_attribute do 3 | end 4 | 5 | factory :miq_custom_attribute, :parent => :custom_attribute do 6 | source 'EVM' 7 | end 8 | 9 | factory :ems_custom_attribute, :parent => :custom_attribute do 10 | source 'VC' 11 | end 12 | end 13 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/amazon_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::AmazonCredential < ManageIQ::Providers::EmbeddedAnsible::AutomationManager::CloudCredential 2 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::AmazonCredential 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/google_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::GoogleCredential < ManageIQ::Providers::EmbeddedAnsible::AutomationManager::CloudCredential 2 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::GoogleCredential 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/network_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::NetworkCredential < ManageIQ::Providers::EmbeddedAnsible::AutomationManager::Credential 2 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::NetworkCredential 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/vmware_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::VmwareCredential < ManageIQ::Providers::EmbeddedAnsible::AutomationManager::CloudCredential 2 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::VmwareCredential 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/inventory/collector/configuration_script_source.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::Inventory::Collector::ConfigurationScriptSource < ManagerRefresh::Inventory::Collector 2 | include ManageIQ::Providers::AnsibleTower::Shared::Inventory::Collector::ConfigurationScriptSource 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/inventory/persister/configuration_script_source.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::Inventory::Persister::ConfigurationScriptSource < ManagerRefresh::Inventory::Persister 2 | include ManageIQ::Providers::AnsibleTower::Shared::Inventory::Persister::ConfigurationScriptSource 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/middleware_manager.rb: -------------------------------------------------------------------------------- 1 | module ManageIQ::Providers 2 | class MiddlewareManager < BaseManager 3 | class << model_name 4 | def route_key 5 | "ems_middleware" 6 | end 7 | 8 | def singular_route_key 9 | "ems_middleware" 10 | end 11 | end 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /product/charts/layouts/daily_perf_charts/Container.yaml: -------------------------------------------------------------------------------- 1 | # Container daily performance chart layouts 2 | --- 3 | - :title: Cores Used 4 | :type: Line 5 | :columns: 6 | - v_derived_cpu_total_cores_used 7 | 8 | - :title: Memory (MB) 9 | :type: Line 10 | :columns: 11 | - derived_memory_used 12 | - derived_memory_available 13 | -------------------------------------------------------------------------------- /product/scan_items/scan_item_cat.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | :item_type: category 3 | :definition: 4 | content: 5 | - target: vmconfig 6 | - target: vmevents 7 | - target: accounts 8 | - target: software 9 | - target: services 10 | - target: system 11 | :name: sample_category 12 | :description: Sample Category Scan 13 | :mode: Vm 14 | -------------------------------------------------------------------------------- /spec/factories/host_aggregate.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :host_aggregate do 3 | sequence(:name) { |n| " host_aggregate_#{seq_padded_for_sorting(n)}" } 4 | end 5 | 6 | factory :host_aggregate_openstack, :parent => :host_aggregate, :class => "ManageIQ::Providers::Openstack::CloudManager::HostAggregate" do 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /spec/models/factory_girl_spec.rb: -------------------------------------------------------------------------------- 1 | describe 'FactoryGirl' do 2 | let(:local_models) { Dir.glob('app/models/*.rb').map { |file| File.basename(file, '.rb').to_sym } } 3 | 4 | it 'All models have a factory defined' do 5 | expect(FactoryGirl.factories.map { |x| x.name.to_sym } & local_models).to match_array(local_models) 6 | end 7 | end 8 | -------------------------------------------------------------------------------- /app/models/configuration_script_source.rb: -------------------------------------------------------------------------------- 1 | class ConfigurationScriptSource < ApplicationRecord 2 | has_many :configuration_script_payloads, :dependent => :destroy 3 | belongs_to :authentication 4 | belongs_to :manager, :class_name => "ExtManagementSystem" 5 | 6 | virtual_total :total_payloads, :configuration_script_payloads 7 | end 8 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/machine_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::MachineCredential < 2 | ManageIQ::Providers::EmbeddedAnsible::AutomationManager::Credential 3 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::MachineCredential 4 | end 5 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/refresher.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::Refresher < ManageIQ::Providers::BaseManager::Refresher 2 | include ::EmsRefresh::Refreshers::EmsRefresherMixin 3 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::Refresher 4 | end 5 | -------------------------------------------------------------------------------- /product/charts/layouts/hourly_perf_charts/Container.yaml: -------------------------------------------------------------------------------- 1 | # Container hourly performance chart layouts 2 | --- 3 | - :title: Cores Used 4 | :type: Line 5 | :columns: 6 | - v_derived_cpu_total_cores_used 7 | 8 | - :title: Memory (MB) 9 | :type: Line 10 | :columns: 11 | - derived_memory_used 12 | - derived_memory_available 13 | -------------------------------------------------------------------------------- /spec/database/data/id_column_whitelist.yml: -------------------------------------------------------------------------------- 1 | --- 2 | authentications: 3 | - ldap_id 4 | - rhsm_pool_id 5 | cloud_networks: 6 | - provider_segmentation_id 7 | container_volumes: 8 | - common_volume_id 9 | miq_queue: 10 | - task_id 11 | network_ports: 12 | - binding_host_id 13 | scan_histories: 14 | - task_id 15 | sessions: 16 | - session_id 17 | -------------------------------------------------------------------------------- /spec/support/custom_matchers/match_string_array_ignorecase.rb: -------------------------------------------------------------------------------- 1 | RSpec::Matchers.define :match_string_array_ignorecase do |expected| 2 | match do |actual| 3 | expect(expected.map(&:downcase)).to match_array(actual.map(&:downcase)) 4 | end 5 | 6 | description do 7 | "a case insensitive string array matcher" 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /app/models/compliance_detail.rb: -------------------------------------------------------------------------------- 1 | class ComplianceDetail < ApplicationRecord 2 | belongs_to :compliance 3 | belongs_to :condition 4 | belongs_to :miq_policy 5 | 6 | virtual_column :resource_name, :type => :string, :uses => {:compliance => :resource} 7 | 8 | def resource_name 9 | compliance.resource.name 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/datawarehouse_manager.rb: -------------------------------------------------------------------------------- 1 | module ManageIQ::Providers 2 | class DatawarehouseManager < BaseManager 3 | class << model_name 4 | def route_key 5 | "ems_datawarehouse" 6 | end 7 | 8 | def singular_route_key 9 | "ems_datawarehouse" 10 | end 11 | end 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/openstack_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::OpenstackCredential < ManageIQ::Providers::EmbeddedAnsible::AutomationManager::CloudCredential 2 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::OpenstackCredential 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/rackspace_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::RackspaceCredential < ManageIQ::Providers::EmbeddedAnsible::AutomationManager::CloudCredential 2 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::RackspaceCredential 3 | end 4 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/satellite6_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::Satellite6Credential < ManageIQ::Providers::EmbeddedAnsible::AutomationManager::CloudCredential 2 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::Satellite6Credential 3 | end 4 | -------------------------------------------------------------------------------- /app/models/service_template_catalog.rb: -------------------------------------------------------------------------------- 1 | class ServiceTemplateCatalog < ApplicationRecord 2 | include TenancyMixin 3 | validates_presence_of :name 4 | validates :name, :uniqueness => {:scope => :tenant_id} 5 | 6 | belongs_to :tenant 7 | has_many :service_templates, :dependent => :nullify 8 | 9 | acts_as_miq_taggable 10 | end 11 | -------------------------------------------------------------------------------- /lib/vmdb/permission_stores/null.rb: -------------------------------------------------------------------------------- 1 | module Vmdb 2 | module PermissionStores 3 | def self.create(_config) 4 | Null.new 5 | end 6 | 7 | class Null 8 | def can?(_permission) 9 | true 10 | end 11 | 12 | def supported_ems_type?(_type) 13 | true 14 | end 15 | end 16 | end 17 | end 18 | -------------------------------------------------------------------------------- /product/charts/layouts/realtime_perf_charts/Container.yaml: -------------------------------------------------------------------------------- 1 | # Container real time performance chart layouts 2 | --- 3 | - :title: Cores Used 4 | :type: Line 5 | :columns: 6 | - v_derived_cpu_total_cores_used 7 | 8 | - :title: Memory (MB) 9 | :type: Line 10 | :columns: 11 | - derived_memory_used 12 | - derived_memory_available 13 | -------------------------------------------------------------------------------- /spec/factories/customization_spec_factory.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :customization_spec do 3 | sequence(:name) { |n| "customization_spec_#{seq_padded_for_sorting(n)}" } 4 | typ { "Windows" } 5 | sequence(:description) { |n| "Customization spec #{seq_padded_for_sorting(n)}" } 6 | spec { { :options => {} } } 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /spec/factories/file_depot_ftp.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory(:file_depot_ftp, :class => "FileDepotFtp", :parent => :file_depot) { uri "ftp://somehost/export" } 3 | factory :file_depot_ftp_with_authentication, :parent => :file_depot_ftp do 4 | after(:create) { |x| x.authentications << FactoryGirl.create(:authentication) } 5 | end 6 | end 7 | -------------------------------------------------------------------------------- /spec/models/container_image_registry_spec.rb: -------------------------------------------------------------------------------- 1 | describe ContainerImageRegistry do 2 | it "#full_name" do 3 | reg = ContainerImageRegistry.new(:name => "docker.io", :host => "docker.io") 4 | expect(reg.full_name).to eq("docker.io") 5 | 6 | reg.port = "1234" 7 | expect(reg.full_name).to eq("docker.io:1234") 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /spec/models/pxe_data/pxelinux.cfg/C0A8FDC7: -------------------------------------------------------------------------------- 1 | timeout 0 2 | default ubuntu-10.10-desktop-amd64 3 | 4 | label ubuntu-10.10-desktop-amd64 5 | kernel ubuntu-10.10-desktop-amd64/vmlinuz 6 | append vga=normal boot=casper netboot=nfs nfsroot=192.168.252.60:/srv/nfsboot/ubuntu-10.10-desktop-amd64 initrd=ubuntu-10.10-desktop-amd64/initrd.lz -- quiet 7 | 8 | -------------------------------------------------------------------------------- /tools/delete_all_error_timeout_queue_messages.rb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require File.expand_path('../config/environment', __dir__) 3 | 4 | cond = {:state => ["error", "timeout"]} 5 | puts "Deleting #{MiqQueue.where(cond).count} queue messages" 6 | 7 | result = MiqQueue.where(cond).delete_all 8 | 9 | puts "Done, deleted #{result} rows" 10 | -------------------------------------------------------------------------------- /tools/import_tags.rb: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env ruby 2 | require File.expand_path('../config/environment', __dir__) 3 | 4 | input = ARGV[0] 5 | raise "No input file provided" if input.nil? 6 | 7 | puts "Importing classification tags..." 8 | File.open(input) { |f| Classification.import_from_yaml(f) } 9 | puts "Importing classification tags... Complete" 10 | -------------------------------------------------------------------------------- /app/models/miq_report/formatters/text.rb: -------------------------------------------------------------------------------- 1 | module MiqReport::Formatters::Text 2 | def to_text 3 | ReportFormatter::ReportRenderer.render(:text) do |e| 4 | e.options.mri = (self) # set the MIQ_Report instance in the formatter 5 | e.options.ignore_table_width = true 6 | end 7 | end 8 | alias_method :to_txt, :to_text 9 | end 10 | -------------------------------------------------------------------------------- /app/models/mixins/cockpit_mixin.rb: -------------------------------------------------------------------------------- 1 | module CockpitMixin 2 | extend ActiveSupport::Concern 3 | def cockpit_server 4 | ext_management_system.try(:zone).try(:remote_cockpit_ws_miq_server) 5 | end 6 | 7 | def cockpit_worker 8 | cockpit_server && MiqCockpitWsWorker.fetch_worker_settings_from_server(cockpit_server) 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /product/scan_items/scan_item_host_event.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | :definition: 3 | content: 4 | - :name: hostd 5 | :filter: 6 | :message: 7 | :level: warn 8 | :rec_count: 0 9 | :source: 10 | :num_days: 2 11 | :description: Sample Host Event Log 12 | :name: sample_host_event_log 13 | :item_type: nteventlog 14 | :mode: Host 15 | -------------------------------------------------------------------------------- /app/models/customization_spec.rb: -------------------------------------------------------------------------------- 1 | class CustomizationSpec < ApplicationRecord 2 | belongs_to :ext_management_system, :foreign_key => "ems_id" 3 | 4 | serialize :spec 5 | 6 | def is_sysprep_spec? 7 | self[:spec].fetch_path(['identity', 'value']).nil? 8 | end 9 | 10 | def is_sysprep_file? 11 | !is_sysprep_spec? 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/embedded_ansible/automation_manager/azure_classic_credential.rb: -------------------------------------------------------------------------------- 1 | class ManageIQ::Providers::EmbeddedAnsible::AutomationManager::AzureClassicCredential < ManageIQ::Providers::EmbeddedAnsible::AutomationManager::CloudCredential 2 | include ManageIQ::Providers::AnsibleTower::Shared::AutomationManager::AzureClassicCredential 3 | end 4 | -------------------------------------------------------------------------------- /app/models/miq_ems_metrics_processor_worker.rb: -------------------------------------------------------------------------------- 1 | class MiqEmsMetricsProcessorWorker < MiqQueueWorkerBase 2 | require_nested :Runner 3 | 4 | self.required_roles = ["ems_metrics_processor"] 5 | self.default_queue_name = "ems_metrics_processor" 6 | 7 | def friendly_name 8 | @friendly_name ||= "C&U Metrics Processor" 9 | end 10 | end 11 | -------------------------------------------------------------------------------- /app/models/miq_schedule_worker.rb: -------------------------------------------------------------------------------- 1 | class MiqScheduleWorker < MiqWorker 2 | require_nested :Jobs 3 | require_nested :Runner 4 | 5 | self.check_for_minimal_role = false 6 | self.workers = lambda { 7 | return MiqServer.minimal_env_options.include?('schedule') ? 1 : 0 if MiqServer.minimal_env? 8 | return 1 9 | } 10 | end 11 | -------------------------------------------------------------------------------- /app/models/mixins/serialized_ems_ref_obj_mixin.rb: -------------------------------------------------------------------------------- 1 | require 'yaml' 2 | 3 | module SerializedEmsRefObjMixin 4 | def ems_ref_obj 5 | ref = read_attribute(:ems_ref_obj) 6 | ref && YAML.load(ref) 7 | end 8 | 9 | def ems_ref_obj=(ref) 10 | ref = YAML.dump(ref) unless ref.nil? 11 | write_attribute(:ems_ref_obj, ref) 12 | end 13 | end 14 | -------------------------------------------------------------------------------- /spec/factories/vm_google.rb: -------------------------------------------------------------------------------- 1 | FactoryGirl.define do 2 | factory :vm_google, :class => "ManageIQ::Providers::Google::CloudManager::Vm", :parent => :vm_cloud do 3 | vendor "google" 4 | 5 | trait :with_provider do 6 | after(:create) do |x| 7 | FactoryGirl.create(:ems_google, :vms => [x]) 8 | end 9 | end 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain1/DOMAIN1/SYSTEM/PROCESS.class/inst1.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:43:52.632636000 Z 5 | updated_on: 2014-05-09 15:43:52.632636000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst1 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain1/DOMAIN1/SYSTEM/PROCESS.class/inst2.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:43:52.635587000 Z 5 | updated_on: 2014-05-09 15:43:52.635587000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst2 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain1/DOMAIN1/SYSTEM/PROCESS.class/inst3.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:43:52.637705000 Z 5 | updated_on: 2014-05-09 15:43:52.637705000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst3 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain1/DOMAIN1/SYSTEM/PROCESS.class/inst4.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:43:52.639843000 Z 5 | updated_on: 2014-05-09 15:43:52.639843000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst4 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain2/DOMAIN2/SYSTEM/PROCESS.class/inst1.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:44:30.244156000 Z 5 | updated_on: 2014-05-09 15:44:30.244156000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst1 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain2/DOMAIN2/SYSTEM/PROCESS.class/inst2.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:44:30.247129000 Z 5 | updated_on: 2014-05-09 15:44:30.247129000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst2 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain2/DOMAIN2/SYSTEM/PROCESS.class/inst31.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:44:30.249279000 Z 5 | updated_on: 2014-05-09 15:44:30.249279000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst31 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain2/DOMAIN2/SYSTEM/PROCESS.class/inst41.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:44:30.251387000 Z 5 | updated_on: 2014-05-09 15:44:30.251387000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst41 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain3/DOMAIN3/SYSTEM/PROCESS.class/inst1.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:44:35.166324000 Z 5 | updated_on: 2014-05-09 15:44:35.166324000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst1 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain3/DOMAIN3/SYSTEM/PROCESS.class/inst2.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:44:35.169230000 Z 5 | updated_on: 2014-05-09 15:44:35.169230000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst2 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain3/DOMAIN3/SYSTEM/PROCESS.class/inst32.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:44:35.171328000 Z 5 | updated_on: 2014-05-09 15:44:35.171328000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst32 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /spec/models/miq_ae_class/data/domain3/DOMAIN3/SYSTEM/PROCESS.class/inst4.yaml: -------------------------------------------------------------------------------- 1 | --- 2 | object_type: instance 3 | version: 1.0 4 | created_on: 2014-05-09 15:44:35.173396000 Z 5 | updated_on: 2014-05-09 15:44:35.173396000 Z 6 | object: 7 | attributes: 8 | display_name: 9 | name: inst4 10 | inherits: 11 | description: 12 | fields: [] 13 | -------------------------------------------------------------------------------- /app/models/manageiq/providers/cloud_manager/provision/configuration.rb: -------------------------------------------------------------------------------- 1 | module ManageIQ::Providers::CloudManager::Provision::Configuration 2 | def userdata_payload 3 | return nil unless customization_template 4 | options = prepare_customization_template_substitution_options 5 | customization_template.script_with_substitution(options) 6 | end 7 | end 8 | --------------------------------------------------------------------------------