@@ -44,7 +44,6 @@ def register_tools(self, mcp: FastMCP):
4444 mcp .tool ()(self .toggle_port_admin_state )
4545 mcp .tool ()(self .get_floating_ips )
4646 mcp .tool ()(self .create_floating_ip )
47- mcp .tool ()(self .allocate_floating_ip_pool_to_project )
4847 mcp .tool ()(self .attach_floating_ip_to_port )
4948 mcp .tool ()(self .detach_floating_ip_from_port )
5049 mcp .tool ()(self .delete_floating_ip )
@@ -418,7 +417,7 @@ def toggle_subnet_dhcp(self, subnet_id: str) -> Subnet:
418417 current = conn .network .get_subnet (subnet_id )
419418 subnet = conn .network .update_subnet (
420419 subnet_id ,
421- enable_dhcp = not current .enable_dhcp ,
420+ enable_dhcp = False if current .enable_dhcp else True ,
422421 )
423422 return self ._convert_to_subnet_model (subnet )
424423
@@ -852,27 +851,6 @@ def create_floating_ip(
852851 ip = conn .network .create_ip (** ip_args )
853852 return self ._convert_to_floating_ip_model (ip )
854853
855- def allocate_floating_ip_pool_to_project (
856- self ,
857- floating_network_id : str ,
858- project_id : str ,
859- ) -> None :
860- """
861- Allocate Floating IP pool (external network access) to a project via RBAC.
862-
863- :param floating_network_id: External network ID
864- :param project_id: Target project ID
865- :return: None
866- """
867- conn = get_openstack_conn ()
868- conn .network .create_rbac_policy (
869- object_type = "network" ,
870- object_id = floating_network_id ,
871- action = "access_as_external" ,
872- target_project_id = project_id ,
873- )
874- return None
875-
876854 def attach_floating_ip_to_port (
877855 self ,
878856 floating_ip_id : str ,
0 commit comments