<commit_before>##################################################################################
# Cloudify OpenStack built in types and plugins definitions.
##################################################################################

imports:
    - cloudify.types

plugins:
    nova_plugin:
        derived_from: cloudify.plugins.manager_plugin
        properties:
            url: https://github.com/cloudify-cosmo/cloudify-openstack-plugin/archive/develop.zip
    neutron_plugin:
        derived_from: cloudify.plugins.manager_plugin
        properties:
            url: https://github.com/cloudify-cosmo/cloudify-openstack-plugin/archive/develop.zip


types:
    cloudify.openstack.server:
        derived_from: cloudify.types.host
        properties:
            - server
            - management_network_name: ''
            - nova_config: {}
            - neutron_config: {}
        interfaces:
            cloudify.interfaces.lifecycle:
                - start: nova_plugin.server.start
                - stop: nova_plugin.server.stop
                - delete: nova_plugin.server.delete
            cloudify.interfaces.host:
                - get_state: nova_plugin.server.get_state

    cloudify.openstack.subnet:
        derived_from: cloudify.types.subnet
        properties:
            - subnet
            - neutron_config: {}
        interfaces:
             cloudify.interfaces.lifecycle:
                  - create: neutron_plugin.subnet.create
                  # deleted together with network

    cloudify.openstack.security_group:
        derived_from: cloudify.types.base
        properties:
            - security_group
            - neutron_config: {}
            - rules: []
            - disable_egress: false
        interfaces:
            cloudify.interfaces.lifecycle:
                - create: neutron_plugin.security_group.create
                - delete: neutron_plugin.security_group.delete

    cloudify.openstack.router:
        derived_from: cloudify.types.router
        properties:
            - router
            - neutron_config: {}
        interfaces:
            cloudify.interfaces.lifecycle:
                - create: neutron_plugin.router.create
                - delete: neutron_plugin.router.delete

    cloudify.openstack.port:
        derived_from: cloudify.types.base
        properties:
            - port
            - neutron_config: {}
        interfaces:
            cloudify.interfaces.lifecycle:
                - create: neutron_plugin.port.create

    cloudify.openstack.network:
        derived_from: cloudify.types.network
        properties:
            - network
            - neutron_config: {}
        interfaces:
            cloudify.interfaces.lifecycle:
                - create: neutron_plugin.network.create
                - delete: neutron_plugin.network.delete

    cloudify.openstack.floatingip:
        derived_from: cloudify.types.base
        properties:
            - floatingip
            - neutron_config: {}
        interfaces:
             cloudify.interfaces.lifecycle:
                  - create: neutron_plugin.floatingip.create
                  - delete: neutron_plugin.floatingip.delete

relationships:
    cloudify.openstack.port_connected_to_security_group:
        derived_from: cloudify.relationships.connected_to
        source_interfaces:
            cloudify.interfaces.relationship_lifecycle:
                - establish: neutron_plugin.port.connect_security_group

    cloudify.openstack.subnet_connected_to_router:
        derived_from: cloudify.relationships.connected_to
        target_interfaces:
            cloudify.interfaces.relationship_lifecycle:
                - establish: neutron_plugin.router.connect_subnet
                - unlink: neutron_plugin.router.disconnect_subnet

    cloudify.openstack.server_connected_to_floating_ip:
        derived_from: cloudify.relationships.connected_to
        source_interfaces:
            cloudify.interfaces.relationship_lifecycle:
                - establish: nova_plugin.server.connect_floatingip
                - unlink: nova_plugin.server.disconnect_floatingip

    cloudify.openstack.server_connected_to_port:
        derived_from: cloudify.relationships.connected_to
        
    cloudify.openstack.floating_ip_connected_to_port:
        derived_from: cloudify.relationships.connected_to
<commit_msg>CFY-145 set default values for router and floatingip properties<commit_after>##################################################################################
# Cloudify OpenStack built in types and plugins definitions.
##################################################################################

imports:
    - cloudify.types

plugins:
    nova_plugin:
        derived_from: cloudify.plugins.manager_plugin
        properties:
            url: https://github.com/cloudify-cosmo/cloudify-openstack-plugin/archive/develop.zip
    neutron_plugin:
        derived_from: cloudify.plugins.manager_plugin
        properties:
            url: https://github.com/cloudify-cosmo/cloudify-openstack-plugin/archive/develop.zip


types:
    cloudify.openstack.server:
        derived_from: cloudify.types.host
        properties:
            - server
            - management_network_name: ''
            - nova_config: {}
            - neutron_config: {}
        interfaces:
            cloudify.interfaces.lifecycle:
                - start: nova_plugin.server.start
                - stop: nova_plugin.server.stop
                - delete: nova_plugin.server.delete
            cloudify.interfaces.host:
                - get_state: nova_plugin.server.get_state

    cloudify.openstack.subnet:
        derived_from: cloudify.types.subnet
        properties:
            - subnet
            - neutron_config: {}
        interfaces:
             cloudify.interfaces.lifecycle:
                  - create: neutron_plugin.subnet.create
                  # deleted together with network

    cloudify.openstack.security_group:
        derived_from: cloudify.types.base
        properties:
            - security_group
            - neutron_config: {}
            - rules: []
            - disable_egress: false
        interfaces:
            cloudify.interfaces.lifecycle:
                - create: neutron_plugin.security_group.create
                - delete: neutron_plugin.security_group.delete

    cloudify.openstack.router:
        derived_from: cloudify.types.router
        properties:
            - router: {}
            - neutron_config: {}
        interfaces:
            cloudify.interfaces.lifecycle:
                - create: neutron_plugin.router.create
                - delete: neutron_plugin.router.delete

    cloudify.openstack.port:
        derived_from: cloudify.types.base
        properties:
            - port
            - neutron_config: {}
        interfaces:
            cloudify.interfaces.lifecycle:
                - create: neutron_plugin.port.create

    cloudify.openstack.network:
        derived_from: cloudify.types.network
        properties:
            - network
            - neutron_config: {}
        interfaces:
            cloudify.interfaces.lifecycle:
                - create: neutron_plugin.network.create
                - delete: neutron_plugin.network.delete

    cloudify.openstack.floatingip:
        derived_from: cloudify.types.base
        properties:
            - floatingip: {}
            - neutron_config: {}
        interfaces:
             cloudify.interfaces.lifecycle:
                  - create: neutron_plugin.floatingip.create
                  - delete: neutron_plugin.floatingip.delete

relationships:
    cloudify.openstack.port_connected_to_security_group:
        derived_from: cloudify.relationships.connected_to
        source_interfaces:
            cloudify.interfaces.relationship_lifecycle:
                - establish: neutron_plugin.port.connect_security_group

    cloudify.openstack.subnet_connected_to_router:
        derived_from: cloudify.relationships.connected_to
        target_interfaces:
            cloudify.interfaces.relationship_lifecycle:
                - establish: neutron_plugin.router.connect_subnet
                - unlink: neutron_plugin.router.disconnect_subnet

    cloudify.openstack.server_connected_to_floating_ip:
        derived_from: cloudify.relationships.connected_to
        source_interfaces:
            cloudify.interfaces.relationship_lifecycle:
                - establish: nova_plugin.server.connect_floatingip
                - unlink: nova_plugin.server.disconnect_floatingip

    cloudify.openstack.server_connected_to_port:
        derived_from: cloudify.relationships.connected_to
        
    cloudify.openstack.floating_ip_connected_to_port:
        derived_from: cloudify.relationships.connected_to

{'fraction_non_alphanumeric': 0.10513753125710389, 'fraction_numerical': 0.0003409865878608775, 'mean_word_length': 2.0744234800838575, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 4, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7584738', 'n_tokens_mistral': 2355, 'n_tokens_neox': 2216, 'n_words': 310}