Changeset 1977 for trunk/packages


Ignore:
Timestamp:
Jan 13, 2009, 3:54:46 PM (16 years ago)
Author:
broder
Message:

Update the nics.hostname field to keep it in sync with machine.name
when VMs are renamed.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/packages/invirt-web/code/main.py

    r1976 r1977  
    380380        if hasattr(validate, 'name'):
    381381            machine.name = validate.name
     382            for n in machine.nics:
     383                if n.hostname == oldname:
     384                    n.hostname = validate.name
    382385        if hasattr(validate, 'description'):
    383386            machine.description = validate.description
Note: See TracChangeset for help on using the changeset viewer.