]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Don't require passing in port_security=False if security_groups present
authorAaron Rosen <aaronorosen@gmail.com>
Wed, 8 Jan 2014 21:10:54 +0000 (13:10 -0800)
committerAaron Rosen <aaronorosen@gmail.com>
Fri, 21 Feb 2014 04:50:35 +0000 (20:50 -0800)
commita5ccc2358dcc2cee5bc8db6a4448f58bae40b67b
tree99943ed5f4e2cfc1e4012d14a61616a252033d73
parent7fb2d579ae5d14fdb538b6f7fde6f58b533c82ba
Don't require passing in port_security=False if security_groups present

If creating a port on a network that is marked as port_security_enabled=False
and one passes in a security_group in the port_create request previously an
error was raised saying they needed to also pass in
port_security_enabled=False. This patch removes that requirement and instead
sets port_security_enabled=True internally if a port has an ip_address and a
security_group is passed in. This is more convient and does not break
backwards compatibility.

Closes-bug: #1267249
Change-Id: Ifb5a5511f016a5d8c5b5075c9fdc27279cdd9bb5
neutron/db/portsecurity_db.py
neutron/tests/unit/test_extension_portsecurity.py