• Home
  • History
  • Annotate
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#!/usr/bin/python
2import db
3
4db = db.db()
5
6for line in open('machines', 'r').readlines():
7    (machine, group) = line.rstrip().split()
8    print 'X %s Y %s' % (machine, group)
9    set = { 'machine_group' : group }
10    where = { 'hostname' : machine }
11    db.update('machines', set, where)
12