Skip to content

Commit 6eee3ba

Browse files
committed
Correct network/port post params for fixedIps
1 parent af7597a commit 6eee3ba

File tree

1 file changed

+19
-2
lines changed

1 file changed

+19
-2
lines changed

src/Networking/v2/Params.php

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -282,10 +282,27 @@ public function macAddr(): array
282282
public function fixedIps(): array
283283
{
284284
return [
285-
'type' => self::STRING_TYPE,
285+
'type' => self::ARRAY_TYPE,
286286
'location' => self::JSON,
287287
'sentAs' => 'fixed_ips',
288-
'description' => 'If you specify only a subnet UUID, OpenStack Networking allocates an available IP from that subnet to the port. If you specify both a subnet UUID and an IP address, OpenStack Networking tries to allocate the address to the port.',
288+
'description' => 'The IP addresses for the port. If you would like to assign multiple IP addresses for the
289+
port, specify multiple entries in this field. Each entry consists of IP address (ipAddress)
290+
and the subnet ID from which the IP address is assigned (subnetId)',
291+
'items' => [
292+
'type' => self::OBJECT_TYPE,
293+
'properties' => [
294+
'ipAdress' => [
295+
'type' => self::STRING_TYPE,
296+
'sentAs' => 'ip_address',
297+
'description' => 'If you specify only an IP address, OpenStack Networking tries to allocate the IP address if the address is a valid IP for any of the subnets on the specified network.'
298+
],
299+
'subnetId' => [
300+
'type' => self::STRING_TYPE,
301+
'sentAs' => 'subnet_id',
302+
'description' => 'Subnet id. If you specify only a subnet ID, OpenStack Networking allocates an available IP from that subnet to the port.'
303+
]
304+
]
305+
]
289306
];
290307
}
291308

0 commit comments

Comments
 (0)