Last change
on this file since 1729 was
1288,
checked in by broder, 16 years ago
|
sipb-xen-database-common -> invirt-database
sipb-xen-database-server -> invirt-database-server
|
-
Property svn:executable set to
*
|
File size:
350 bytes
|
Rev | Line | |
---|
[77] | 1 | #!/usr/bin/env python |
---|
| 2 | |
---|
[836] | 3 | from invirt import database |
---|
[77] | 4 | import sys |
---|
| 5 | |
---|
| 6 | def usage(): |
---|
| 7 | print >>sys.stderr, "Usage: %s [create|drop]" %(sys.argv[0],) |
---|
| 8 | sys.exit(-1) |
---|
| 9 | |
---|
| 10 | if len(sys.argv) == 1: |
---|
| 11 | usage() |
---|
| 12 | |
---|
[836] | 13 | database.connect() |
---|
[77] | 14 | |
---|
| 15 | if sys.argv[1] == "create": |
---|
[836] | 16 | database.meta.create_all() |
---|
[241] | 17 | elif sys.argv[1] == "drop": |
---|
[836] | 18 | database.meta.drop_all() |
---|
[77] | 19 | else: |
---|
[241] | 20 | usage() |
---|
Note: See
TracBrowser
for help on using the repository browser.