cyclades: Extend flavors with 'allow_create' field
cyclades: Add 'userid' and 'public' to subnets
Extend 'Subnet' model with 'userid' and 'public' attributes. This isrequired in order to avoid an expensive join when listing subnets. Thiscommit also includes a database migration for existing subnets.
cyclades: Add 'ipversion' to IPAddress model
cyclades: Fix broken tests
Fix default values for DB model factories.
cyclades: Fix migration file
Fix migration that caused creation of Subnet for networks that did nothad enabled the 'dhcp' option.
cyclades: Add datetime fields to Subnet model
Add 'created' and 'updated' datetime fields in Subnet model.
cyclades: Fix bugs in port creation
cyclades: Add a function to check name legnth
cyclades: Speedup db data migrations
cyclades: Fix duplicate constraint in DB
cyclades: Fix typo in DB migration file
cyclades: Remove DEFAULT_ROUTING_TABLE setting
Do not have a default value from 'link' attribute of IP_LESS_ROUTEDnetworks. Instead if the admin does not specify a value innetwork-create command, uniquely name the networks by with theBACKEND_PREFIX_ID and network id, e.g. snf-link-42.
cyclades: Fix bug in IP pools migration
Since the size of IP pools is not automatically computed by the sizeof corresponding subnet, the data migration must add sizes to allexisting IP pools.
Add some missing Copyright notices
Also add 2013 in package COPYRIGHT files.
Merge branch 'master' into develop
Conflicts: ci/schemas/one_node_wheezy/wheezy.conf docs/admin-guide.rst snf-cyclades-app/synnefo/api/actions.py snf-cyclades-app/synnefo/api/servers.py snf-cyclades-app/synnefo/logic/backend.py snf-cyclades-app/synnefo/logic/callbacks.py...
cyclades: Enforce quota
Introduce command enforce-resources-cyclades, which checks for quotaviolations and applies actions to enforce the limits. By default, itoperates only on these resources: cpu, ram, floating_ip.
cyclades: Add name to Ganeti NICs
Add 'name' attribute to newly created NICs. Currently, the name of theNICs will not be used to refer to NICs, as it will be in Synnefo 0.15.Names are added only to ease the migration to version 0.15. Also, thiscommit updates snf-dispatcher to preserve the name of the NIC, if any,...
cyclades: Delete stale NICs before migration
Extend migration file to delete NICs that belong to VMs that havealready been deleted. Such NICs may exist due to a bug in previous versionsof Synnefo, and are totally useless. Also, they must be removed because...
cyclades: Update firewall_profile field to None
Migration value of 'firewall_profile' attribute from '' to None.
helpdesk: Support quering history of public IPs
Add basic support for quering a public IP address. All uses of this IPaddress are returned which are currently rendered to a dummy template.
cyclades: Small bug fix in IP Pools
cyclades: More strict 'on_delete' for models
Use 'models.PROTECT' for 'on_delete' attribute for some ForeignKeyrelationship between networking models. This will create a more "strict" database and protect for unexpected data loss.
cyclades: Fix bug in SeparatedValuesField
Return [] instead of None, if the field is null.
cyclades: Create IPv6 Addresses from dispatcher
When ports are created from the API they do not have an IPv6 address.The IPv6 address is only available after the MAC address of theNIC is known which is only available after the message from theGaneti backend has been received. However, dispatcher did not created...
cyclades: Fix bug in tests
Fix bug in port tests that were introduced by latest changes in IPPoolmanager.
Cyclades: Rename 'Can not' to 'Cannot' to all msgs
cyclades: Fix bug and typo in IPPool
cyclades: Fix handling of old IP pools
Before implementing the Neutron API, each network had one IP pool thatcontained the whole subnet CIDR. This changed since now we have multipleIP Pools(with base and offset attributes) per network and this IP pools...
cyclades: Series of fixes regarding networks & ips
cyclades: Add snf-manage subnet-inspect
cyclades: Fix permissions when looking up ports
Look up of ports should check the port userid and not the networkuserid.
cyclades: Port userid can not be null
cyclades: Create server with existing ports
Extend POST /servers API call to support creation of servers that willbe using existing ports. Networking of the instance is defined via the'networks' attribute which can contain either network UUIDs or portUUIDs. In case of network UUIDs, the user can also request for a...
cyclades: Create ports without 'device_id'
Allow creation of ports that are not connected to any instance. Suchports will be in 'DOWN' state. To allow this, 'machine' attribute ofNetworkInterface model has been made to allow null values. Finally, the'logic.ports' module has been remove, and the corresponding code has...
cyclades: Add accounting for IP Addresses
Create IPAddressLog DB table to hold information about allocation of IPaddresses to virtual servers. The information that is currently savedcontains the IP address, the ID of the virtual server, the ID of thevirtual network along with the datetime that the address has been...
cyclades: Fix bugs relative to pool allocation
Fix bug when trying to allocate a specified IPv4 address. Only one ofthe IP pools will contain this address, so you must bypass InvalidValueexceptions until searching all pools.
Also PoolManager raised 'EmptyPool' exception when trying to allocate from an...
cyclades: Mock GANETI_USE_HOTPLUG on ports tests
Test that you can not create or delete a port on a machinethat is started if GANETI_USE_HOTPLUG is set to False.
cyclades: Rename Port state from BUILDING to BUILD
Neutron API defines the 'BUILD' status. This commit renames BUILDING state of NIC to BUILD.
cyclades: Update floating-ips api
Make changes to the floating-ips ip so that it complies with theOpenstack Quantum API.
cyclades: Fix default values for IP pool
Temporary commit to change default offset and size of IPPoolTablefactory.
cyclades: Make tests work with multiple IP pools
Refactor tests so that they are aware that a network can have multipleIP pools. Also, add extra check to PoolManager methods in order to checkwhether a value is contained in the pool.
cyclades: Fix bugs in IP pools
Fix default value for 'external' argument of release_address method ofNetwork model. Also fix how is checked whether an IP pool contains anaddress.
cyclades: Various fixes to networks/subnets/pools
cyclades: Fix reconciliation for network and pools
cyclades: Remove stale reference to 'router'
cyclades: Default name for ports and subnets
cyclades: Add migratrion for external_router field
Add data migration for 'external_router' fields. This field is set toTrue for all 'public' networks.
Revert "cyclades: Add /routers api"
This reverts commit 69dadbe4e3223dc4d8cbaa5b09dde755c15679ed. Temporaryremove the /routers API.
cyclades: snf-manage floating-ip-attach
snf-manage floating-ip-attach <address> --machine <server_id/router_id>
cyclades: Add /routers api
cyclades: Add message to exceptions
cyclades: Hack-ish commit for old IP pools
cyclades: Fully support ip pools in subnets
cyclades: Fix some network management commands
cyclades: Refactor backend code for new networks
cyclades: Fix getting value from pool
If an address is specified, check that the value belong to the pool,else raise InvalidValue.
cyclades: Add method to get ip stats to network
Extend Network model with a method to get the number of free and totalIPv4 addresses of the network. Also, add method to IPAddress model torelease its IPv4 address if any. Finally, update backend-list management...
cyclades: Add option to get value from pool
Extend PoolManager 'get' method to also take as argument a value toget from the pool. If the value is already reserved, then aValueNotAvailable exception will be raised.
cyclades: snf-manage port-list
cyclades: Optimize DB queries of /servers API
Use 'prefetch_related' attribute of Django queryset to prefetch theNetworkInterface and IPaddress objects that are related with aVirtualMachine object. Also, modify functions that operate on serverNICs and IPs, to to use only the prefetched objects, which means that...
cyclades: Fix DB tests
cyclades: Make logic tests pass
Refactor Cyclades code so that it follows the new models for Networks,Subnets and IPAddresses. This refactor is not complete. Instead is thenecessary refactor for making tests for server API calls succeed.
cyclades: Add /ports api call
cyclades: Make API server tests pass
cyclades: Make IPPool manager work for subnets
Temporary commit to make IPPool manager work. This will work only ifthere is only one allocation pool for each subnet.
cyclades: Change 'null' attribute of Subnet models
cyclades: Add missing migration file
cyclades: Use a constant for name length of models
Use a constant for declaring the max length of the name of amodel
cyclades: Update models_factory
Update models factory to match the new models.
Signed-off-by: Marios Kogias <marioskogias@grnet.gr>Signed-off-by: Dionysis Grigoropoulos <dgrig@grnet.gr>
cyclades: Remove unused fields and model from DB
Remove unused 'ipv4' and 'ipv6' attributes from NetworkInterface modeland totally remove FloatingIP model. This information has been movedin commit 972a428 to IPAddress model.
cyclades: Data migration from NIC to IPAddress
Migrate db data from NetworkInterface model to IPAddress model.
cyclades: Major refactor on NIC model
Major refactor on db models concerning NetworkInterface models. A newtable, namely 'IPAddress' has been created to represent an IPAddress(IPv4 or IPv6). Each IPAddress is related with a network and the subnetfrom which it has been allocated. Also it contains 'floating_ip' attribute...
cyclades: Remove unused fields from Network model
Remove unused fields from Network: subnet, subnet6, gateway, gateway6,dhcp and pool. The following attributes have been moved to Subnet modelin commit 779c887. Also extend model with the 'external_router'...
cyclades: Add new Subnet model
Add Subnet model containing Layer-3 characteristics for networks. Also,extend IPPoolTable object to hold a reference to the Subnet that thepool belongs to.
Signed-off-by: Dionysis Grigoropoulos <dgrig@grnet.gr>
cyclades: Add DB data migration for subnets
Migrate attributes from old Network model to new Subnet model.
cyclades: Do not delete FIPs if VM is deleted
Remove on delete CASCADE for floating IPs if the VirtualMachine isdeleted.
cyclades: Clear FloatingIP when deleting NIC
Override 'delete' method of NetworkInterface model, to clear the'machine' flag of the corresponding NIC, if any.
cyclades: Add 'ip_type' attribute to NIC
Extend NetworkInterface model with the 'ip_type' attribute to showwhether the IP is a floating or fixed.
Signed-off-by: Christos Stavrakakis <cstavr@grnet.gr>
cyclades: Use Ganeti NIC UUIDs
Since Ganeti 2.8, it is supported to refer to devices (NICs and Disks)not only by their index but also by their name or UUID. This commitupdates Synnefo to refer to devices by their name. Synnefo will set thename of the devices which will be a UUID. We do not use Ganeti's UUIDs...
cyclades: Make (network, ipv4) unique for each NIC
Add a unique constraint to NetworkInterface model. This constraintasserts that the same IPv4 address from the same network will no beassigned to more than one NICs.
cyclades: Refactor reconciliation of pools
Move reconciliation of IP pools from 'snf-manage reconcile-networks'to 'snf-manage reconcile-pools'. Also change the way reconciliationworks: Instead of reconciling the IP pools in DB with the IP pools inGaneti, the new reconciliation just checks that:...
cyclades: Fix str representation for pool objects
cyclades: Add missing migration for commit 3bb0b11
cyclades: Add 'on_delete' to all ForeignKeys
Add 'on_delete' argument to all ForeignKeys. The value of thisargument depends on the type of each relation.
cyclades: Remove custom ForUpdateManager
Remove custom manager that implemented select_for_update(), since thisis already implemented in Django 1.4.
cyclades: Remove custom ProtectedDeletedManager
Remove custom ProtectedDeletedManager. Instead use theForeignKey.on_delete attribute that has been introduced in Django 1.4.
cyclades: Fix bug in custom field
Rename get_db_prep_value to get_prep_value. In django 1.4 the second oneis just a wrapper for the first one.
cyclades: Extend Backend model with disk_templates
Extend 'Backend' models with 'disk_template' attribute, that containsthe list of disk templates that are available in each backend.
cyclades: Add SeparatedValuesList field
Add custom field for storing a list of values in DB. The valuesare stored as a TextField separated by a delimiter.
cyclades: Handle errors during vm creation
Commit #f2080d1 mocked an OP_INSTANCE_REMOVE when enqueuing anOP_INSTANCE_CREATE job to Ganeti failed. However, this may result inreleasing IPs that may get reserved in Ganeti, because we can neverreally know if the job has reached Ganeti or not (e.g. timeout). For...
Merge branch 'hotfix-0.14.6' into develop
Conflicts: Changelog docs/admin-guide.rst snf-cyclades-app/synnefo/api/management/commands/network-remove.py snf-cyclades-app/synnefo/api/servers.py snf-cyclades-app/synnefo/api/tests/servers.py snf-cyclades-app/synnefo/logic/backend.py...
cyclades: Make index field of NIC optional
Change 'index' field of NIC model to be optional, because the index ofbuilding NICs is unknown. Also, change all API responses to return onlythe active NICs.
cyclades: Fix bug in snf-dispatcher logic
This commit reverts commits #07602322 and #30514662 which introduced abug in dispatcher's logic. These commit fixed the issue that, in a casethe Cyclades DB is unsynced with Ganeti, a resource that does not exist...
cyclades: Import settings from django.conf
cyclades: More verbose models representation
Make unicode method of VirtualMachine, Network and FloatingIP models moreverbose.
cyclades: Remove wrong model attribute
cyclades: Add migration file for IPv6 networks
cyclades: Fix exception message
cyclades: Support IPv6 only networks
Make Cyclades support IPv6 only networks. Such networks will havethe 'subnet' attribute set to None, in the same way that IPv4 onlynetworks have the 'subnet6' attribute set to None.
Because currently Ganeti does not support IPv6 only networks, we create the...
Merge branch 'hotfix-0.14.2' into develop
Conflicts: Changelog snf-astakos-app/astakos/im/messages.py snf-astakos-app/astakos/im/views/target/__init__.py snf-cyclades-app/synnefo/logic/backend.py snf-cyclades-app/synnefo/logic/management/commands/reconcile-servers.py...