3 from invirt import database
7 print >>sys.stderr, "Usage: %s [create|drop]" %(sys.argv[0],)
10 if len(sys.argv) == 1:
14 database.meta.create_all()
15 session = database.session()
17 if not database.Type.query.get('linux-hvm'):
18 session.save(database.Type(type_id='linux-hvm', description='HVM',
19 hvm='t', apic='t', acpi='t', pae='t'))
20 if not database.Type.query.get('linux'):
21 session.save(database.Type(type_id='linux', description='ParaVM',
22 hvm='f', apic='f', acpi='f', pae='f'))
27 if sys.argv[1] == "create":
29 elif sys.argv[1] == "drop":
30 database.meta.drop_all()