Просмотр исходного кода

Add minion_pools API to api-refs

Daniel Vincze 5 лет назад
Родитель
Сommit
517785212a

+ 3 - 0
coriolis/api-refs/api_samples/minion_pool/minion-pool-allocate-req.json

@@ -0,0 +1,3 @@
+{
+    "allocate": null
+}

+ 3 - 0
coriolis/api-refs/api_samples/minion_pool/minion-pool-deallocate-req.json

@@ -0,0 +1,3 @@
+{
+    "deallocate": null
+}

+ 108 - 0
coriolis/api-refs/api_samples/minion_pool/minion-pool-list-resp.json

@@ -0,0 +1,108 @@
+{
+    "minion_pools": [
+        {
+            "id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+            "name": "source_pool",
+            "notes": "",
+            "endpoint_id": "8e9b6b0b-ef3b-4127-ac32-a18a30e67749",
+            "environment_options": {
+                "list_all_destination_networks": false,
+                "migr_worker_use_config_drive": false,
+                "migr_image": "bionic",
+                "migr_network": "admin-net",
+                "migr_flavor_name": "m1.small",
+                "migr_worker_use_fip": true,
+                "migr_worker_boot_from_volume": false,
+                "migr_fip_pool_name": "b2f0b98e-03a1-4f13-92aa-ece55f34ebf8/038a72ea-1413-493b-82da-4c75a9077fbf"
+            },
+            "os_type": "linux",
+            "maintenance_trust_id": "525a0b79388c43f38d23770a57038780",
+            "platform": "source",
+            "created_at": "2021-01-29T11:18:24.000000",
+            "updated_at": "2021-01-29T11:51:05.000000",
+            "deleted_at": null,
+            "deleted": "0",
+            "shared_resources": {},
+            "status": "ALLOCATED",
+            "minimum_minions": 1,
+            "maximum_minions": 3,
+            "minion_max_idle_time": 600,
+            "minion_retention_strategy": "poweroff",
+            "minion_machines": [
+                {
+                    "id": "ecb4d684-9339-4ad1-9116-96ddb11d5bb6",
+                    "user_id": "bdb2d792fc0c48818ef4b1b1240fbb69",
+                    "project_id": "f801306887294bf0b98ffc05601f22db",
+                    "created_at": "2021-01-29T11:49:38.000000",
+                    "updated_at": "2021-01-29T11:51:05.000000",
+                    "deleted_at": null,
+                    "deleted": "0",
+                    "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                    "allocation_status": "AVAILABLE",
+                    "power_status": "POWERED_ON",
+                    "connection_info": {
+                        "ip": "10.107.5.65",
+                        "port": 22,
+                        "username": "cloudbase",
+                        "password": null,
+                        "pkey": "***"
+                    },
+                    "allocated_action": null,
+                    "last_used_at": "2021-01-29T11:51:05.000000",
+                    "backup_writer_connection_info": {
+                        "backend": "ssh_backup_writer",
+                        "connection_details": {
+                            "ip": "10.107.5.65",
+                            "port": 22,
+                            "username": "cloudbase",
+                            "password": null,
+                            "pkey": "***"
+                        }
+                    },
+                    "provider_properties": {
+                        "instance_id": "13971ab6-f523-4290-958f-6f5d8edf180f",
+                        "keypair_name": "coriolispool540a29dfmachineecb4d68493394ad1911696ddb112fe9eb68keypair",
+                        "port_id": "14c2c8b8-a0c2-481a-8687-b0fbbd62e436",
+                        "data_transfer_mechanism": "SSH",
+                        "secgroup_id": "5750cecb-2354-413e-87ae-14dc50eb2459",
+                        "floating_ip_id": "9f3a3ab2-42d6-4d8a-8f26-71f8bd380ae6",
+                        "pool_identifier": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                        "minion_identifier": "ecb4d684-9339-4ad1-9116-96ddb11d5bb6",
+                        "pool_shared_resources": {},
+                        "pool_os_type": "linux"
+                    }
+                }
+            ]
+        },
+        {
+            "id": "be74a17c-5476-4cf8-93f7-dd58c700de70",
+            "name": "destination_pool",
+            "notes": null,
+            "endpoint_id": "a471879c-8138-4440-ad0a-7c201d4ed7df",
+            "environment_options": {
+                "data_transfer_mechanism": "HTTPS",
+                "migr_flavor_name": "m1.medium",
+                "migr_image": "64df7925-fc27-4fce-80ed-63d85918064f",
+                "migr_network": "admin-net",
+                "migr_worker_boot_from_volume": false,
+                "migr_worker_use_config_drive": false,
+                "migr_worker_use_fip": false,
+                "list_all_destination_networks": true
+            },
+            "os_type": "windows",
+            "maintenance_trust_id": "71718e42267f44c5988beac7260159db",
+            "platform": "destination",
+            "created_at": "2021-01-29T11:55:55.000000",
+            "updated_at": null,
+            "deleted_at": null,
+            "deleted": "0",
+            "shared_resources": null,
+            "status": "DEALLOCATED",
+            "minimum_minions": 1,
+            "maximum_minions": 1,
+            "minion_max_idle_time": 3600,
+            "minion_retention_strategy": "delete",
+            "minion_machines": []
+        }
+    ]
+}

+ 3 - 0
coriolis/api-refs/api_samples/minion_pool/minion-pool-refresh-req.json

@@ -0,0 +1,3 @@
+{
+    "refresh": null
+}

+ 74 - 0
coriolis/api-refs/api_samples/minion_pool/openstack-minion-pool-allocate-resp.json

@@ -0,0 +1,74 @@
+{
+    "minion_pool": {
+        "created_at": "2021-01-29T11:18:24.000000",
+        "updated_at": "2021-01-29T11:49:07.000000",
+        "deleted_at": null,
+        "deleted": "0",
+        "id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+        "user_id": "bdb2d792fc0c48818ef4b1b1240fbb69",
+        "project_id": "f801306887294bf0b98ffc05601f22db",
+        "maintenance_trust_id": "525a0b79388c43f38d23770a57038780",
+        "name": "source_pool",
+        "notes": "",
+        "endpoint_id": "8e9b6b0b-ef3b-4127-ac32-a18a30e67749",
+        "os_type": "linux",
+        "platform": "source",
+        "environment_options": {
+            "list_all_destination_networks": false,
+            "migr_worker_use_config_drive": false,
+            "migr_image": "bionic",
+            "migr_network": "admin-net",
+            "migr_flavor_name": "m1.small",
+            "migr_worker_use_fip": true,
+            "migr_worker_boot_from_volume": false,
+            "migr_fip_pool_name": "b2f0b98e-03a1-4f13-92aa-ece55f34ebf8/038a72ea-1413-493b-82da-4c75a9077fbf"
+        },
+        "status": "IN_MAINTENANCE",
+        "shared_resources": null,
+        "minimum_minions": 1,
+        "maximum_minions": 3,
+        "minion_max_idle_time": 600,
+        "minion_retention_strategy": "poweroff",
+        "minion_machines": [],
+        "events": [
+            // ...
+            {
+                "created_at": "2021-01-29T11:49:07.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "e08c4162-2ff3-4540-8bc4-da17a5105158",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "level": "INFO",
+                "index": 13,
+                "message": "Begun minion pool allocation process"
+            }
+        ],
+        "progress_updates": [
+            {
+                "created_at": "2021-01-29T11:41:01.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "5133f40d-5b14-488d-9e7b-eb091d42341c",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "index": 0,
+                "current_step": 0,
+                "total_steps": 0,
+                "message": "Compiling minion pool options"
+            },
+            {
+                "created_at": "2021-01-29T11:47:27.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "02ed776d-417c-4bfe-b451-a508ffacdb83",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "index": 1,
+                "current_step": 0,
+                "total_steps": 0,
+                "message": "There are no shared minion pool resources requiring teardown for OpenStack"
+            }
+        ]
+    }
+}

+ 23 - 0
coriolis/api-refs/api_samples/minion_pool/openstack-minion-pool-create-req.json

@@ -0,0 +1,23 @@
+{
+    "minion_pool": {
+        "name": "source_pool",
+        "endpoint_id": "8e9b6b0b-ef3b-4127-ac32-a18a30e67749",
+        "os_type": "linux",
+        "platform": "source",
+        "minimum_minions": 1,
+        "maximum_minions": 1,
+        "minion_max_idle_time": 1,
+        "minion_retention_strategy": "delete",
+        "notes": "",
+        "skip_allocation": true,
+        "environment_options": {
+            "list_all_destination_networks": false,
+            "migr_worker_use_config_drive": false,
+            "migr_image": "bionic",
+            "migr_network": "admin-net",
+            "migr_flavor_name": "m1.small",
+            "migr_worker_use_fip": true,
+            "migr_worker_boot_from_volume": false
+        }
+    }
+}

+ 47 - 0
coriolis/api-refs/api_samples/minion_pool/openstack-minion-pool-create-resp.json

@@ -0,0 +1,47 @@
+{
+    "minion_pool": {
+        "created_at": "2021-01-29T11:18:24.000000",
+        "updated_at": null,
+        "deleted_at": null,
+        "deleted": "0",
+        "id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+        "user_id": "bdb2d792fc0c48818ef4b1b1240fbb69",
+        "project_id": "f801306887294bf0b98ffc05601f22db",
+        "maintenance_trust_id": "525a0b79388c43f38d23770a57038780",
+        "name": "source_pool",
+        "notes": "",
+        "endpoint_id": "8e9b6b0b-ef3b-4127-ac32-a18a30e67749",
+        "os_type": "linux",
+        "platform": "source",
+        "environment_options": {
+            "list_all_destination_networks": false,
+            "migr_worker_use_config_drive": false,
+            "migr_image": "bionic",
+            "migr_network": "admin-net",
+            "migr_flavor_name": "m1.small",
+            "migr_worker_use_fip": true,
+            "migr_worker_boot_from_volume": false
+        },
+        "status": "DEALLOCATED",
+        "shared_resources": null,
+        "minimum_minions": 1,
+        "maximum_minions": 1,
+        "minion_max_idle_time": 1,
+        "minion_retention_strategy": "delete",
+        "minion_machines": [],
+        "events": [
+            {
+                "created_at": "2021-01-29T11:18:24.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "9999e14b-53e1-4528-a59d-0194748c4a87",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "level": "INFO",
+                "index": 0,
+                "message": "Successfully added minion pool to the DB"
+            }
+        ],
+        "progress_updates": []
+    }
+}

+ 95 - 0
coriolis/api-refs/api_samples/minion_pool/openstack-minion-pool-deallocate-resp.json

@@ -0,0 +1,95 @@
+{
+    "minion_pool": {
+        "created_at": "2021-01-29T11:18:24.000000",
+        "updated_at": "2021-01-29T12:03:56.000000",
+        "deleted_at": null,
+        "deleted": "0",
+        "id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+        "user_id": "bdb2d792fc0c48818ef4b1b1240fbb69",
+        "project_id": "f801306887294bf0b98ffc05601f22db",
+        "maintenance_trust_id": "525a0b79388c43f38d23770a57038780",
+        "name": "source_pool",
+        "notes": "",
+        "endpoint_id": "8e9b6b0b-ef3b-4127-ac32-a18a30e67749",
+        "os_type": "linux",
+        "platform": "source",
+        "environment_options": {
+            "list_all_destination_networks": false,
+            "migr_worker_use_config_drive": false,
+            "migr_image": "bionic",
+            "migr_network": "admin-net",
+            "migr_flavor_name": "m1.small",
+            "migr_worker_use_fip": true,
+            "migr_worker_boot_from_volume": false,
+            "migr_fip_pool_name": "b2f0b98e-03a1-4f13-92aa-ece55f34ebf8/038a72ea-1413-493b-82da-4c75a9077fbf"
+        },
+        "status": "IN_MAINTENANCE",
+        "shared_resources": {},
+        "minimum_minions": 1,
+        "maximum_minions": 3,
+        "minion_max_idle_time": 600,
+        "minion_retention_strategy": "poweroff",
+        "minion_machines": [
+            {
+                "created_at": "2021-01-29T11:49:38.000000",
+                "updated_at": "2021-01-29T12:02:39.000000",
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "ecb4d684-9339-4ad1-9116-96ddb11d5bb6",
+                "user_id": "bdb2d792fc0c48818ef4b1b1240fbb69",
+                "project_id": "f801306887294bf0b98ffc05601f22db",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "allocation_status": "AVAILABLE",
+                "allocated_action": null,
+                "power_status": "POWERED_ON",
+                "last_used_at": "2021-01-29T11:51:05.000000",
+                "connection_info": {
+                    "ip": "10.107.5.65",
+                    "port": 22,
+                    "username": "cloudbase",
+                    "password": null,
+                    "pkey": "***"
+                },
+                "backup_writer_connection_info": {
+                    "backend": "ssh_backup_writer",
+                    "connection_details": {
+                        "ip": "10.107.5.65",
+                        "port": 22,
+                        "username": "cloudbase",
+                        "password": null,
+                        "pkey": "***"
+                    }
+                },
+                "provider_properties": {
+                    "instance_id": "13971ab6-f523-4290-958f-6f5d8edf180f",
+                    "keypair_name": "coriolispool540a29dfmachineecb4d68493394ad1911696ddb112fe9eb68keypair",
+                    "port_id": "14c2c8b8-a0c2-481a-8687-b0fbbd62e436",
+                    "data_transfer_mechanism": "SSH",
+                    "secgroup_id": "5750cecb-2354-413e-87ae-14dc50eb2459",
+                    "floating_ip_id": "9f3a3ab2-42d6-4d8a-8f26-71f8bd380ae6",
+                    "pool_identifier": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                    "minion_identifier": "ecb4d684-9339-4ad1-9116-96ddb11d5bb6",
+                    "pool_shared_resources": {},
+                    "pool_os_type": "linux"
+                }
+            }
+        ],
+        "events": [
+            // ...
+            {
+                "created_at": "2021-01-29T12:03:56.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "6048989e-f49c-4562-967d-764ae5f9bd69",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "level": "INFO",
+                "index": 29,
+                "message": "Begun minion pool deallocation process"
+            }
+        ],
+        "progress_updates": [
+            // ...
+        ]
+    }
+}

+ 95 - 0
coriolis/api-refs/api_samples/minion_pool/openstack-minion-pool-refresh-resp.json

@@ -0,0 +1,95 @@
+{
+    "minion_pool": {
+        "created_at": "2021-01-29T11:18:24.000000",
+        "updated_at": "2021-01-29T11:51:05.000000",
+        "deleted_at": null,
+        "deleted": "0",
+        "id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+        "user_id": "bdb2d792fc0c48818ef4b1b1240fbb69",
+        "project_id": "f801306887294bf0b98ffc05601f22db",
+        "maintenance_trust_id": "525a0b79388c43f38d23770a57038780",
+        "name": "source_pool",
+        "notes": "",
+        "endpoint_id": "8e9b6b0b-ef3b-4127-ac32-a18a30e67749",
+        "os_type": "linux",
+        "platform": "source",
+        "environment_options": {
+            "list_all_destination_networks": false,
+            "migr_worker_use_config_drive": false,
+            "migr_image": "bionic",
+            "migr_network": "admin-net",
+            "migr_flavor_name": "m1.small",
+            "migr_worker_use_fip": true,
+            "migr_worker_boot_from_volume": false,
+            "migr_fip_pool_name": "b2f0b98e-03a1-4f13-92aa-ece55f34ebf8/038a72ea-1413-493b-82da-4c75a9077fbf"
+        },
+        "status": "ALLOCATED",
+        "shared_resources": {},
+        "minimum_minions": 1,
+        "maximum_minions": 3,
+        "minion_max_idle_time": 600,
+        "minion_retention_strategy": "poweroff",
+        "minion_machines": [
+            {
+                "created_at": "2021-01-29T11:49:38.000000",
+                "updated_at": "2021-01-29T12:02:23.000000",
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "ecb4d684-9339-4ad1-9116-96ddb11d5bb6",
+                "user_id": "bdb2d792fc0c48818ef4b1b1240fbb69",
+                "project_id": "f801306887294bf0b98ffc05601f22db",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "allocation_status": "HEALTHCHECKING",
+                "allocated_action": null,
+                "power_status": "POWERED_ON",
+                "last_used_at": "2021-01-29T11:51:05.000000",
+                "connection_info": {
+                    "ip": "10.107.5.65",
+                    "port": 22,
+                    "username": "cloudbase",
+                    "password": null,
+                    "pkey": "***"
+                },
+                "backup_writer_connection_info": {
+                    "backend": "ssh_backup_writer",
+                    "connection_details": {
+                        "ip": "10.107.5.65",
+                        "port": 22,
+                        "username": "cloudbase",
+                        "password": null,
+                        "pkey": "***"
+                    }
+                },
+                "provider_properties": {
+                    "instance_id": "13971ab6-f523-4290-958f-6f5d8edf180f",
+                    "keypair_name": "coriolispool540a29dfmachineecb4d68493394ad1911696ddb112fe9eb68keypair",
+                    "port_id": "14c2c8b8-a0c2-481a-8687-b0fbbd62e436",
+                    "data_transfer_mechanism": "SSH",
+                    "secgroup_id": "5750cecb-2354-413e-87ae-14dc50eb2459",
+                    "floating_ip_id": "9f3a3ab2-42d6-4d8a-8f26-71f8bd380ae6",
+                    "pool_identifier": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                    "minion_identifier": "ecb4d684-9339-4ad1-9116-96ddb11d5bb6",
+                    "pool_shared_resources": {},
+                    "pool_os_type": "linux"
+                }
+            }
+        ],
+        "events": [
+            // ...
+            {
+                "created_at": "2021-01-29T12:02:23.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "cde729b2-b1c6-41d7-907c-7cc39bc5ed7a",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "level": "INFO",
+                "index": 26,
+                "message": "Begun minion pool refreshing process"
+            }
+        ],
+        "progress_updates": [
+            // ...
+        ]
+    }
+}

+ 130 - 0
coriolis/api-refs/api_samples/minion_pool/openstack-minion-pool-show.json

@@ -0,0 +1,130 @@
+{
+    "minion_pool": {
+        "created_at": "2021-01-29T11:18:24.000000",
+        "updated_at": "2021-01-29T11:51:05.000000",
+        "deleted_at": null,
+        "deleted": "0",
+        "id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+        "user_id": "bdb2d792fc0c48818ef4b1b1240fbb69",
+        "project_id": "f801306887294bf0b98ffc05601f22db",
+        "maintenance_trust_id": "525a0b79388c43f38d23770a57038780",
+        "name": "source_pool",
+        "notes": "",
+        "endpoint_id": "8e9b6b0b-ef3b-4127-ac32-a18a30e67749",
+        "os_type": "linux",
+        "platform": "source",
+        "environment_options": {
+            "list_all_destination_networks": false,
+            "migr_worker_use_config_drive": false,
+            "migr_image": "bionic",
+            "migr_network": "admin-net",
+            "migr_flavor_name": "m1.small",
+            "migr_worker_use_fip": true,
+            "migr_worker_boot_from_volume": false,
+            "migr_fip_pool_name": "b2f0b98e-03a1-4f13-92aa-ece55f34ebf8/038a72ea-1413-493b-82da-4c75a9077fbf"
+        },
+        "status": "ALLOCATED",
+        "shared_resources": {},
+        "minimum_minions": 1,
+        "maximum_minions": 3,
+        "minion_max_idle_time": 600,
+        "minion_retention_strategy": "poweroff",
+        "minion_machines": [
+            {
+                "created_at": "2021-01-29T11:49:38.000000",
+                "updated_at": "2021-01-29T11:51:05.000000",
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "ecb4d684-9339-4ad1-9116-96ddb11d5bb6",
+                "user_id": "bdb2d792fc0c48818ef4b1b1240fbb69",
+                "project_id": "f801306887294bf0b98ffc05601f22db",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "allocation_status": "AVAILABLE",
+                "allocated_action": null,
+                "power_status": "POWERED_ON",
+                "last_used_at": "2021-01-29T11:51:05.000000",
+                "connection_info": {
+                    "ip": "10.107.5.65",
+                    "port": 22,
+                    "username": "cloudbase",
+                    "password": null,
+                    "pkey": "***"
+                },
+                "backup_writer_connection_info": {
+                    "backend": "ssh_backup_writer",
+                    "connection_details": {
+                        "ip": "10.107.5.65",
+                        "port": 22,
+                        "username": "cloudbase",
+                        "password": null,
+                        "pkey": "***"
+                    }
+                },
+                "provider_properties": {
+                    "instance_id": "13971ab6-f523-4290-958f-6f5d8edf180f",
+                    "keypair_name": "coriolispool540a29dfmachineecb4d68493394ad1911696ddb112fe9eb68keypair",
+                    "port_id": "14c2c8b8-a0c2-481a-8687-b0fbbd62e436",
+                    "data_transfer_mechanism": "SSH",
+                    "secgroup_id": "5750cecb-2354-413e-87ae-14dc50eb2459",
+                    "floating_ip_id": "9f3a3ab2-42d6-4d8a-8f26-71f8bd380ae6",
+                    "pool_identifier": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                    "minion_identifier": "ecb4d684-9339-4ad1-9116-96ddb11d5bb6",
+                    "pool_shared_resources": {},
+                    "pool_os_type": "linux"
+                }
+            }
+        ],
+        "events": [
+            {
+                "created_at": "2021-01-29T11:18:24.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "9999e14b-53e1-4528-a59d-0194748c4a87",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "level": "INFO",
+                "index": 0,
+                "message": "Successfully added minion pool to the DB"
+            },
+            {
+                "created_at": "2021-01-29T11:34:53.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "33309ecf-6ecc-4452-9007-fa25e1499ce6",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "level": "INFO",
+                "index": 1,
+                "message": "Successfully updated minion pool properties"
+            }
+            // ...
+        ],
+        "progress_updates": [
+            {
+                "created_at": "2021-01-29T11:41:01.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "5133f40d-5b14-488d-9e7b-eb091d42341c",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "index": 0,
+                "current_step": 0,
+                "total_steps": 0,
+                "message": "Compiling minion pool options"
+            },
+            {
+                "created_at": "2021-01-29T11:47:27.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "02ed776d-417c-4bfe-b451-a508ffacdb83",
+                "pool_id": "540a29df-94e4-4a65-bf3b-40ea18929c40",
+                "index": 1,
+                "current_step": 0,
+                "total_steps": 0,
+                "message": "There are no shared minion pool resources requiring teardown for OpenStack"
+            }
+            // ...
+        ]
+    }
+}

+ 21 - 0
coriolis/api-refs/api_samples/minion_pool/openstack-minion-pool-update-req.json

@@ -0,0 +1,21 @@
+{
+    "minion_pool": {
+        "name": "dest_pool_linux",
+        "minimum_minions": 2,
+        "maximum_minions": 3,
+        "minion_max_idle_time": 600,
+        "minion_retention_strategy": "poweroff",
+        "os_type": "linux",
+        "notes": "Converted from Windows Minion Pool",
+        "environment_options": {
+            "list_all_destination_networks": false,
+            "migr_worker_use_config_drive": false,
+            "migr_image": "bionic",
+            "migr_network": "admin-net",
+            "migr_flavor_name": "m1.small",
+            "migr_worker_use_fip": true,
+            "migr_worker_boot_from_volume": false,
+            "migr_fip_pool_name": "b2f0b98e-03a1-4f13-92aa-ece55f34ebf8/038a72ea-1413-493b-82da-4c75a9077fbf"
+        }
+    }
+}

+ 60 - 0
coriolis/api-refs/api_samples/minion_pool/openstack-minion-pool-update-resp.json

@@ -0,0 +1,60 @@
+{
+    "minion_pool": {
+        "created_at": "2021-01-29T11:55:55.000000",
+        "updated_at": "2021-01-29T14:46:25.000000",
+        "deleted_at": null,
+        "deleted": "0",
+        "id": "be74a17c-5476-4cf8-93f7-dd58c700de70",
+        "user_id": "bdb2d792fc0c48818ef4b1b1240fbb69",
+        "project_id": "f801306887294bf0b98ffc05601f22db",
+        "maintenance_trust_id": "71718e42267f44c5988beac7260159db",
+        "name": "dest_pool_linux",
+        "notes": "Converted from Windows Minion Pool",
+        "endpoint_id": "a471879c-8138-4440-ad0a-7c201d4ed7df",
+        "os_type": "linux",
+        "platform": "destination",
+        "environment_options": {
+            "list_all_destination_networks": false,
+            "migr_worker_use_config_drive": false,
+            "migr_image": "bionic",
+            "migr_network": "admin-net",
+            "migr_flavor_name": "m1.small",
+            "migr_worker_use_fip": true,
+            "migr_worker_boot_from_volume": false,
+            "migr_fip_pool_name": "b2f0b98e-03a1-4f13-92aa-ece55f34ebf8/038a72ea-1413-493b-82da-4c75a9077fbf",
+            "data_transfer_mechanism": "SSH"
+        },
+        "status": "DEALLOCATED",
+        "shared_resources": null,
+        "minimum_minions": 2,
+        "maximum_minions": 3,
+        "minion_max_idle_time": 600,
+        "minion_retention_strategy": "poweroff",
+        "minion_machines": [],
+        "events": [
+            {
+                "created_at": "2021-01-29T11:55:55.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "618beb44-91a3-458b-a0da-ee19638447df",
+                "pool_id": "be74a17c-5476-4cf8-93f7-dd58c700de70",
+                "level": "INFO",
+                "index": 0,
+                "message": "Successfully added minion pool to the DB"
+            },
+            {
+                "created_at": "2021-01-29T14:46:25.000000",
+                "updated_at": null,
+                "deleted_at": null,
+                "deleted": "0",
+                "id": "080cd191-dc2f-4cbc-81b4-5b9d073bf953",
+                "pool_id": "be74a17c-5476-4cf8-93f7-dd58c700de70",
+                "level": "INFO",
+                "index": 1,
+                "message": "Successfully updated minion pool properties"
+            }
+        ],
+        "progress_updates": []
+    }
+}

+ 1 - 0
coriolis/api-refs/source/index.rst

@@ -9,5 +9,6 @@ This is a reference for the Coriolis API.
 .. include:: diagnostics.inc
 .. include:: endpoint.inc
 .. include:: migration.inc
+.. include:: minion_pool.inc
 .. include:: provider.inc
 .. include:: replica.inc

+ 482 - 0
coriolis/api-refs/source/minion_pool.inc

@@ -0,0 +1,482 @@
+.. -*- rst -*-
+
+============
+Minion Pools
+============
+
+Lists, creates, updates, shows details for and deletes minion pools. It also allocates, deallocates and refreshes information for minion machines for minion pools.
+
+
+List Minion Pools
+=================
+
+.. rest_method:: GET /minion_pools
+
+List details for all minion pools.
+
+Normal response codes: 200
+
+Error response codes: unauthorized(401),
+forbidden(403), itemNotFound(404)
+
+Response
+--------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pools : minion_pools_array
+  - id : minion_pool_id
+  - name : minion_pool_name
+  - notes : minion_pool_notes
+  - endpoint_id : minion_pool_endpoint_id
+  - environment_options : minion_pool_environment_options
+  - os_type : minion_pool_os_type
+  - maintenance_trust_id : minion_pool_maintenance_trust_id
+  - platform : minion_pool_platform
+  - created_at : minion_pool_created_at
+  - updated_at : minion_pool_updated_at
+  - deleted_at : minion_pool_deleted_at
+  - deleted : minion_pool_deleted
+  - shared_resources : minion_pool_shared_resources
+  - status : minion_pool_status
+  - minimum_minions : minimum_minions
+  - maximum_minions : maximum_minions
+  - minion_max_idle_time : minion_max_idle_time
+  - minion_retention_strategy : minion_pool_retention_strategy
+  - minion_machines : minion_pool_machines
+
+**Example of Minion Pool List Response**
+
+.. literalinclude:: ../api_samples/minion_pool/minion-pool-list-resp.json
+    :language: javascript
+
+
+Show Minion Pool
+================
+
+.. rest_method:: GET /minion_pools/{minion_pool_id}
+
+Shows details about a minion pool.
+
+**Preconditions**
+
+The minion pool must exist.
+
+Normal response codes: 200
+
+Error response codes: unauthorized(401),
+forbidden(403), itemNotFound(404)
+
+Request
+-------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pool_id : minion_pool_id_path
+
+Response
+--------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pool : minion_pool_object
+  - id : minion_pool_id
+  - name : minion_pool_name
+  - notes : minion_pool_notes
+  - endpoint_id : minion_pool_endpoint_id
+  - environment_options : minion_pool_environment_options
+  - os_type : minion_pool_os_type
+  - maintenance_trust_id : minion_pool_maintenance_trust_id
+  - platform : minion_pool_platform
+  - created_at : minion_pool_created_at
+  - updated_at : minion_pool_updated_at
+  - deleted_at : minion_pool_deleted_at
+  - deleted : minion_pool_deleted
+  - shared_resources : minion_pool_shared_resources
+  - status : minion_pool_status
+  - minimum_minions : minimum_minions
+  - maximum_minions : maximum_minions
+  - minion_max_idle_time : minion_max_idle_time
+  - minion_retention_strategy : minion_pool_retention_strategy
+  - minion_machines : minion_pool_machines
+  - user_id : user_id
+  - project_id : project_id
+  - events : minion_pool_events
+  - progress_updates : minion_pool_progress_updates
+
+**Example of Minion Pool Show Response**
+
+  .. literalinclude:: ../api_samples/minion_pool/openstack-minion-pool-show.json
+      :language: javascript
+
+Create Minion Pool
+==================
+
+.. rest_method:: POST /minion_pools
+
+Creates a minion pool.
+
+Normal response codes: 200
+
+Error response codes: unauthorized(401),
+forbidden(403)
+
+Request
+-------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pool : minion_pool_object
+  - name : minion_pool_name
+  - notes : minion_pool_notes
+  - endpoint_id : minion_pool_endpoint_id
+  - environment_options : minion_pool_environment_options
+  - os_type : minion_pool_os_type
+  - platform : minion_pool_platform
+  - minimum_minions : minimum_minions
+  - maximum_minions : maximum_minions
+  - minion_max_idle_time : minion_max_idle_time
+  - minion_retention_strategy : minion_pool_retention_strategy
+  - skip_allocation : minion_pool_skip_allocation
+
+**Example of Minion Pool Create Request**
+
+  .. literalinclude:: ../api_samples/minion_pool/openstack-minion-pool-create-req.json
+      :language: javascript
+
+Response
+--------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pool : minion_pool_object
+  - id : minion_pool_id
+  - name : minion_pool_name
+  - notes : minion_pool_notes
+  - endpoint_id : minion_pool_endpoint_id
+  - environment_options : minion_pool_environment_options
+  - os_type : minion_pool_os_type
+  - maintenance_trust_id : minion_pool_maintenance_trust_id
+  - platform : minion_pool_platform
+  - created_at : minion_pool_created_at
+  - updated_at : minion_pool_updated_at
+  - deleted_at : minion_pool_deleted_at
+  - deleted : minion_pool_deleted
+  - shared_resources : minion_pool_shared_resources
+  - status : minion_pool_status
+  - minimum_minions : minimum_minions
+  - maximum_minions : maximum_minions
+  - minion_max_idle_time : minion_max_idle_time
+  - minion_retention_strategy : minion_pool_retention_strategy
+  - minion_machines : minion_pool_machines
+  - user_id : user_id
+  - project_id : project_id
+  - events : minion_pool_events
+  - progress_updates : minion_pool_progress_updates
+
+**Example of Minion Pool Create Response**
+
+  .. literalinclude:: ../api_samples/minion_pool/openstack-minion-pool-create-resp.json
+      :language: javascript
+
+Update Minion Pool
+==================
+
+.. rest_method:: PUT /minion_pools/{minion_pool_id}
+
+Updates a minion pool.
+
+**Preconditions**
+
+The minion pool must exist and be in DEALLOCATED state.
+
+Normal response codes: 200
+
+Error response codes: unauthorized(401), forbidden(403),
+itemNotFound(404)
+
+Request
+-------
+
+  .. rest_parameters:: parameters.yaml
+
+    - minion_pool_id : minion_pool_id_path
+    - minion_pool : minion_pool_object
+    - name : minion_pool_name
+    - notes : minion_pool_notes
+    - endpoint_id : minion_pool_endpoint_id
+    - environment_options : minion_pool_environment_options
+    - os_type : minion_pool_os_type
+    - platform : minion_pool_platform
+    - minimum_minions : minimum_minions
+    - maximum_minions : maximum_minions
+    - minion_max_idle_time : minion_max_idle_time
+    - minion_retention_strategy : minion_pool_retention_strategy
+    - notes : minion_pool_notes
+
+**Example of Minion Pool Update Request**
+
+.. literalinclude:: ../api_samples/minion_pool/openstack-minion-pool-update-req.json
+    :language: javascript
+
+Response
+--------
+
+  .. rest_parameters:: parameters.yaml
+
+    - minion_pool : minion_pool_object
+    - id : minion_pool_id
+    - name : minion_pool_name
+    - notes : minion_pool_notes
+    - endpoint_id : minion_pool_endpoint_id
+    - environment_options : minion_pool_environment_options
+    - os_type : minion_pool_os_type
+    - maintenance_trust_id : minion_pool_maintenance_trust_id
+    - platform : minion_pool_platform
+    - created_at : minion_pool_created_at
+    - updated_at : minion_pool_updated_at
+    - deleted_at : minion_pool_deleted_at
+    - deleted : minion_pool_deleted
+    - shared_resources : minion_pool_shared_resources
+    - status : minion_pool_status
+    - minimum_minions : minimum_minions
+    - maximum_minions : maximum_minions
+    - minion_max_idle_time : minion_max_idle_time
+    - minion_retention_strategy : minion_pool_retention_strategy
+    - minion_machines : minion_pool_machines
+    - user_id : user_id
+    - project_id : project_id
+    - events : minion_pool_events
+    - progress_updates : minion_pool_progress_updates
+
+**Example of Minion Pool Update Response**
+
+.. literalinclude:: ../api_samples/minion_pool/openstack-minion-pool-update-resp.json
+    :language: javascript
+
+Delete Minion Pool
+==================
+
+.. rest_method:: DELETE /minion_pools/{minion_pool_id}
+
+Deletes a Minion Pool.
+
+**Preconditions**
+
+The Minion Pool must exist and be in DEALLOCATED state.
+
+Normal response codes: 204
+
+Error response codes: unauthorized(401), forbidden(403),
+itemNotFound(404)
+
+Request
+-------
+
+.. rest_parameters:: parameters.yaml
+
+   - minion_pool_id : minion_pool_id_path
+
+Response
+--------
+
+There is no response body for a successful deletion.
+
+
+Minion Pool Actions
+===================
+
+Minion Pool Allocate
+====================
+
+.. rest_method:: POST /minion_pools/{minion_pool_id}/actions
+
+Allocates Minion Machines for a Minion Pool.
+
+**Preconditions**
+
+The minion pool must exist and be in DEALLOCATED state.
+
+
+Normal response codes: 200
+
+Error response codes:
+unauthorized(401), forbidden(403), itemNotFound(404)
+
+Request
+-------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pool_id : minion_pool_id_path
+  - allocate : minion_pool_allocate
+
+**Example of Minion Pool Allocation Request**
+
+  .. literalinclude:: ../api_samples/minion_pool/minion-pool-allocate-req.json
+      :language: javascript
+
+Response
+--------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pool : minion_pool_object
+  - id : minion_pool_id
+  - name : minion_pool_name
+  - notes : minion_pool_notes
+  - endpoint_id : minion_pool_endpoint_id
+  - environment_options : minion_pool_environment_options
+  - os_type : minion_pool_os_type
+  - maintenance_trust_id : minion_pool_maintenance_trust_id
+  - platform : minion_pool_platform
+  - created_at : minion_pool_created_at
+  - updated_at : minion_pool_updated_at
+  - deleted_at : minion_pool_deleted_at
+  - deleted : minion_pool_deleted
+  - shared_resources : minion_pool_shared_resources
+  - status : minion_pool_status
+  - minimum_minions : minimum_minions
+  - maximum_minions : maximum_minions
+  - minion_max_idle_time : minion_max_idle_time
+  - minion_retention_strategy : minion_pool_retention_strategy
+  - minion_machines : minion_pool_machines
+  - user_id : user_id
+  - project_id : project_id
+  - events : minion_pool_events
+  - progress_updates : minion_pool_progress_updates
+
+**Example of Minion Pool Allocation Response**
+
+  .. literalinclude:: ../api_samples/minion_pool/openstack-minion-pool-allocate-resp.json
+      :language: javascript
+
+Minion Pool Deallocate
+======================
+
+.. rest_method:: POST /minion_pools/{minion_pool_id}/actions
+
+Deallocates Minion Machines for a Minion Pool.
+
+**Preconditions**
+
+The minion pool must exist and be in ALLOCATED or ERROR state.
+
+
+Normal response codes: 200
+
+Error response codes:
+unauthorized(401), forbidden(403), itemNotFound(404)
+
+Request
+-------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pool_id : minion_pool_id_path
+  - deallocate : minion_pool_deallocate
+
+**Example of Minion Pool Deallocation Request**
+
+  .. literalinclude:: ../api_samples/minion_pool/minion-pool-deallocate-req.json
+      :language: javascript
+
+Response
+--------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pool : minion_pool_object
+  - id : minion_pool_id
+  - name : minion_pool_name
+  - notes : minion_pool_notes
+  - endpoint_id : minion_pool_endpoint_id
+  - environment_options : minion_pool_environment_options
+  - os_type : minion_pool_os_type
+  - maintenance_trust_id : minion_pool_maintenance_trust_id
+  - platform : minion_pool_platform
+  - created_at : minion_pool_created_at
+  - updated_at : minion_pool_updated_at
+  - deleted_at : minion_pool_deleted_at
+  - deleted : minion_pool_deleted
+  - shared_resources : minion_pool_shared_resources
+  - status : minion_pool_status
+  - minimum_minions : minimum_minions
+  - maximum_minions : maximum_minions
+  - minion_max_idle_time : minion_max_idle_time
+  - minion_retention_strategy : minion_pool_retention_strategy
+  - minion_machines : minion_pool_machines
+  - user_id : user_id
+  - project_id : project_id
+  - events : minion_pool_events
+  - progress_updates : minion_pool_progress_updates
+
+**Example of Minion Pool Deallocation Response**
+
+  .. literalinclude:: ../api_samples/minion_pool/openstack-minion-pool-deallocate-resp.json
+      :language: javascript
+
+Minion Pool Refresh
+======================
+
+.. rest_method:: POST /minion_pools/{minion_pool_id}/actions
+
+Refreshes Minion Machines for a Minion Pool.
+
+**Preconditions**
+
+The minion pool must exist and be in ALLOCATED state.
+
+
+Normal response codes: 200
+
+Error response codes:
+unauthorized(401), forbidden(403), itemNotFound(404)
+
+Request
+-------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pool_id : minion_pool_id_path
+  - refresh : minion_pool_refresh
+
+**Example of Minion Pool Refresh Request**
+
+  .. literalinclude:: ../api_samples/minion_pool/minion-pool-refresh-req.json
+      :language: javascript
+
+Response
+--------
+
+.. rest_parameters:: parameters.yaml
+
+  - minion_pool : minion_pool_object
+  - id : minion_pool_id
+  - name : minion_pool_name
+  - notes : minion_pool_notes
+  - endpoint_id : minion_pool_endpoint_id
+  - environment_options : minion_pool_environment_options
+  - os_type : minion_pool_os_type
+  - maintenance_trust_id : minion_pool_maintenance_trust_id
+  - platform : minion_pool_platform
+  - created_at : minion_pool_created_at
+  - updated_at : minion_pool_updated_at
+  - deleted_at : minion_pool_deleted_at
+  - deleted : minion_pool_deleted
+  - shared_resources : minion_pool_shared_resources
+  - status : minion_pool_status
+  - minimum_minions : minimum_minions
+  - maximum_minions : maximum_minions
+  - minion_max_idle_time : minion_max_idle_time
+  - minion_retention_strategy : minion_pool_retention_strategy
+  - minion_machines : minion_pool_machines
+  - user_id : user_id
+  - project_id : project_id
+  - events : minion_pool_events
+  - progress_updates : minion_pool_progress_updates
+
+**Example of Minion Pool Refresh Response**
+
+  .. literalinclude:: ../api_samples/minion_pool/openstack-minion-pool-refresh-resp.json
+      :language: javascript

+ 173 - 0
coriolis/api-refs/source/parameters.yaml

@@ -23,6 +23,12 @@ migration_id_path:
   in: path
   required: true
   type: uuid
+minion_pool_id_path:
+  description: |
+    The ID of the minion pool.
+  in: path
+  type: uuid
+  required: true
 platform:
   description: |
     The type of cloud service platform.
@@ -299,6 +305,12 @@ instance_osmorphing_minion_pool_mappings:
   in: body
   type: object
   required: true
+maximum_minions:
+  description: |
+    Maximum number of minion machines allowed to be allocated for the minion pool.
+  in: body
+  type: integer
+  required: false
 migration_cancel:
   description: |
     Object containing information about the type of migration cancellation.
@@ -436,6 +448,167 @@ migrations_array:
   in: body
   type: array
   required: true
+minimum_minions:
+  description: |
+    Minimum number of minion machines to be allocated for the minion pool.
+  in: body
+  type: integer
+  required: false
+minion_max_idle_time:
+  description: |
+    Number of seconds for the minion machines of a minion_pool to be allowed in idle state before executing its retention strategy.
+  in: body
+  type: integer
+  required: false
+minion_pool_allocate:
+  description: |
+    An object that describes minion pool allocation action.
+  in: body
+  type: object
+  required: true
+minion_pool_created_at:
+  description: |
+    Timestamp of minion pool creation.
+  in: body
+  type: string
+  required: true
+minion_pool_deallocate:
+  description: |
+    An object that describes minion pool deallocation action.
+  in: body
+  type: object
+  required: true
+minion_pool_deleted:
+  description: |
+    Whether a minion pool is deleted or not.
+    1 for deleted
+    0 for not deleted
+  in: body
+  type: string
+  required: true
+minion_pool_deleted_at:
+  description: |
+    Timestamp of minion pool deletion.
+  in: body
+  type: string
+  required: true
+minion_pool_endpoint_id:
+  description: |
+    The ID of the minion pool endpoint.
+  in: body
+  type: uuid
+  required: true
+minion_pool_environment_options:
+  description: |
+    The configuration for the minion machines of the minion pool.
+  in: body
+  type: object
+  required: true
+minion_pool_events:
+  description: |
+    Array of events occuring on the minion pool.
+  in: body
+  type: array
+  required: true
+minion_pool_id:
+  description: |
+    The ID of the minion pool.
+  in: body
+  type: uuid
+  required: true
+minion_pool_machines:
+  description: |
+    Array of minion machine objects allocated in a minion_pool.
+  in: body
+  type: array
+  required: true
+minion_pool_maintenance_trust_id:
+  description: |
+    Maintenance trust_id of the minion pool.
+  in: body
+  type: uuid
+  required: true
+minion_pool_name:
+  description: |
+    The name of the minion pool.
+  in: body
+  type: string
+  required: true
+minion_pool_notes:
+  description: |
+    Notes about the minion pool.
+  in: body
+  type: string
+  required: false
+minion_pool_object:
+  description: |
+    Object containing information about a minion pool.
+  in: body
+  type: object
+  required: true
+minion_pool_os_type:
+  description: |
+    The OS type for the minion machines of this minion pool.
+  in: body
+  type: string
+  required: true
+minion_pool_platform:
+  description: |
+    The platform of the minion pool. Can either be 'source' or 'destination'.
+  in: body
+  type: string
+  required: true
+minion_pool_progress_updates:
+  description: |
+    Array of progress updates for minion machines of a minion pool.
+  in: body
+  type: array
+  required: true
+minion_pool_refresh:
+  description: |
+    An object describing minion pool refresh action.
+  in: body
+  type: object
+  required: true
+minion_pool_retention_strategy:
+  description: |
+    The retention strategy used for the minion machines of the minion pool. Can either be 'delete' or 'poweroff'.
+  in: body
+  type: string
+  required: false
+minion_pool_shared_resources:
+  description: |
+    Mapping of shared resources and their respective IDs for the minion machines of the minion pool.
+  in: body
+  type: object
+  required: true
+minion_pool_skip_allocation:
+  description: |
+    Boolean indicating whether or not to skip allocating machines upon minion pool creation.
+  in: body
+  type: boolean
+  required: false
+minion_pool_status:
+  description: |
+    The status of the minion pool. Accepted values: 'UNKNOWN', 'ERROR',
+    'DEALLOCATED', 'VALIATING_INPUTS', 'ALLOCATING_SHARED_RESOURCES',
+    'ALLOCATING_MACHINES', 'DEALLOCATING_MACHINES',
+    'DEALLOCATING_SHARED_RESOURCES', 'ALLOCATED', 'IN_MAINTENANCE'.
+  in: body
+  type: string
+  required: true
+minion_pool_updated_at:
+  description: |
+    Timestamp of minion pool update.
+  in: body
+  type: string
+  required: true
+minion_pools_array:
+  description: |
+    The array of minion pools.
+  in: body
+  type: array
+  required: true
 network_id:
   description: |
     The unique identifier of a network.