Project

General

Custom queries

Profile

Actions

Bug #21405

open

Search param doesn't work with the 'thin' host list

Added by Sean O'Keeffe over 7 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

[root@centos7-katello-nightly ~]# curl H "Accept:application/json,version=2" -H "Content-Type:application/json" -u admin:changeme -k https://$(hostname -f)/api/hosts?thin=true?search=content_view_id+%3D+1 | python -m json.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 250 0 250 0 0 2497 0 -
:--:-- --:--:-- --:--:-- 2525 {
"page": 1,
"per_page": 20,
"results": [ {
"id": 2,
"name": "adjad.sean.example.com"
}, {
"id": 1,
"name": "centos7-katello-nightly.sean.example.com"
}
],
"search": null,
"sort": {
"by": null,
"order": null
},
"subtotal": 2,
"total": 2
}
[root@centos7-katello-nightly ~]# curl H "Accept:application/json,version=2" -H "Content-Type:application/json" -u admin:changeme -k https://$(hostname -f)/api/hosts?search=content_view_id+%3D+1 | python -m json.tool
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 2589 0 2589 0 0 15915 0 -
:--:-- --:--:-- --:--:-- 15981 {
"page": 1,
"per_page": 20,
"results": [ {
"architecture_id": null,
"architecture_name": null,
"build": false,
"capabilities": [
"build"
],
"certname": "adjad.sean.example.com",
"comment": "",
"compute_profile_id": null,
"compute_profile_name": null,
"compute_resource_id": null,
"compute_resource_name": null,
"configuration_status": 0,
"configuration_status_label": "No reports",
"content_facet_attributes": {
"applicable_package_count": 0,
"content_source": null,
"content_source_id": null,
"content_source_name": null,
"content_view": {
"id": 1,
"name": "Default Organization View"
},
"content_view_id": 1,
"content_view_name": "Default Organization View",
"errata_counts": {
"bugfix": null,
"enhancement": null,
"security": null,
"total": null
},
"id": 2,
"kickstart_repository_id": null,
"lifecycle_environment": {
"id": 1,
"name": "Library"
},
"lifecycle_environment_id": 1,
"lifecycle_environment_name": "Library",
"upgradable_package_count": 0,
"uuid": null
},
"created_at": "2017-10-18 15:29:47 UTC",
"disk": null,
"domain_id": 1,
"domain_name": "sean.example.com",
"enabled": true,
"environment_id": 1,
"environment_name": "production",
"global_status": 0,
"global_status_label": "Warning",
"hostgroup_id": null,
"hostgroup_name": null,
"hostgroup_title": null,
"id": 2,
"image_file": "",
"image_id": null,
"image_name": null,
"installed_at": null,
"ip": null,
"ip6": "",
"last_compile": null,
"last_report": null,
"location_id": null,
"location_name": null,
"mac": null,
"managed": false,
"medium_id": null,
"medium_name": null,
"model_id": 1,
"model_name": "Standard PC (i440FX + PIIX, 1996)",
"name": "adjad.sean.example.com",
"operatingsystem_id": null,
"operatingsystem_name": null,
"organization_id": 1,
"organization_name": "Default Organization",
"owner_id": 4,
"owner_name": "Admin User",
"owner_type": "User",
"provision_method": "build",
"ptable_id": null,
"ptable_name": null,
"puppet_ca_proxy": {
"id": 1,
"name": "centos7-katello-nightly.sean.example.com",
"url": "https://centos7-katello-nightly.sean.example.com:9090"
},
"puppet_ca_proxy_id": 1,
"puppet_ca_proxy_name": "centos7-katello-nightly.sean.example.com",
"puppet_proxy": {
"id": 1,
"name": "centos7-katello-nightly.sean.example.com",
"url": "https://centos7-katello-nightly.sean.example.com:9090"
},
"puppet_proxy_id": 1,
"puppet_proxy_name": "centos7-katello-nightly.sean.example.com",
"puppet_status": 0,
"pxe_loader": null,
"realm_id": null,
"realm_name": null,
"sp_ip": null,
"sp_mac": null,
"sp_name": null,
"sp_subnet_id": null,
"subnet6_id": null,
"subnet6_name": null,
"subnet_id": null,
"subnet_name": null,
"updated_at": "2017-10-18 15:29:47 UTC",
"use_image": null,
"uuid": null
}
],
"search": "content_view_id = 1",
"sort": {
"by": null,
"order": null
},
"subtotal": 1,
"total": 2
}
[root@centos7-katello-nightly ~]#

No data to display

Actions

Also available in: Atom PDF