New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add physical server profile template #81
add physical server profile template #81
Conversation
...nageiq/providers/cisco_intersight/physical_infra_manager/physical_server_profile_template.rb
Outdated
Show resolved
Hide resolved
...nageiq/providers/cisco_intersight/physical_infra_manager/physical_server_profile_template.rb
Outdated
Show resolved
Hide resolved
...nageiq/providers/cisco_intersight/physical_infra_manager/physical_server_profile_template.rb
Outdated
Show resolved
Hide resolved
...nageiq/providers/cisco_intersight/physical_infra_manager/physical_server_profile_template.rb
Outdated
Show resolved
Hide resolved
...nageiq/providers/cisco_intersight/physical_infra_manager/physical_server_profile_template.rb
Outdated
Show resolved
Hide resolved
app/models/manageiq/providers/cisco_intersight/physical_infra_manager/ems_refresh_workflow.rb
Outdated
Show resolved
Hide resolved
move deploy_server_from_template_queue to core set the deploy_server_from_template function to be an instance method
def refresh | ||
task_ids = EmsRefresh.queue_refresh_task(ext_management_system) | ||
if task_ids.blank? | ||
process_error("Failed to queue refresh", "error") | ||
queue_signal(:error) | ||
else | ||
context[:refresh_task_ids] = task_ids | ||
update!(:context => context) | ||
|
||
queue_signal(:poll_refresh) | ||
end | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
NOTE this looks identical to the method in core except for the target_entity/ext_management_system bit. It would be nice to add a refresh_target
method in core that defaults to target_entity
if targeted_refresh is supported and ext_management_system
otherwise which would allow you to override it and simply return ext_management_system
if you just want to do a full.
Would be a good follow-up PR if you want to implement that in core.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Specs found a good issue, looks like you need to subclass the PhysicalServerProfileTemplate under your PhysicalInfraManager (make sure to remember the |
...nageiq/providers/cisco_intersight/physical_infra_manager/physical_server_profile_template.rb
Outdated
Show resolved
Hide resolved
I added the require_nested :PhysicalServerProfileTemplate to the PhysicalInfraManager is it ok? can you rerun the tests? |
@@ -33778,6 +33778,185 @@ http_interactions: | |||
] | |||
} | |||
http_version: | |||
recorded_at: Thu, 12 May 2022 13:46:56 GMT- request: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a YAML syntax error
recorded_at: Thu, 12 May 2022 13:46:56 GMT- request: | |
recorded_at: Thu, 12 May 2022 13:46:56 GMT | |
- request: |
{ | ||
"ObjectType": "server.ProfileTemplate.List", | ||
"Results": | ||
[ | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
{ | |
"ObjectType": "server.ProfileTemplate.List", | |
"Results": | |
[ | |
{ | |
{ | |
"ObjectType": "server.Profile.List", | |
"Results": [ | |
{ |
Then indent the rest of this accordingly
@eilam20 looks like the vcr was manually edited, and since you have your |
If you want to allow maintainer edits I can push my local changes where I got this green |
I pushed the change, but how can I allow maintainer edits? |
@eilam20 you can also run the specs locally by running |
Here are my local changes to get this green. I'm not sure what editor you're using but the indentation on the YAML is way off |
...iders_CiscoIntersight_PhysicalInfraManager_Refresher/refresh/will_perform_a_full_refresh.yml
Show resolved
Hide resolved
...iders_CiscoIntersight_PhysicalInfraManager_Refresher/refresh/will_perform_a_full_refresh.yml
Outdated
Show resolved
Hide resolved
...iders_CiscoIntersight_PhysicalInfraManager_Refresher/refresh/will_perform_a_full_refresh.yml
Show resolved
Hide resolved
@agrare how can I run only the spec of the cisco provider? |
Checked commits Autosde/manageiq-providers-cisco_intersight@6dd1444~...324e40e with ruby 2.6.10, rubocop 1.28.2, haml-lint 0.35.0, and yamllint |
@eilam20 if you are in the |
@agrare I see that the tests ran successfully, so it can be merged? |
woohoo 🎉 |
Add the physical_server_profile_templates to Physical Infra Manager.