Exemplo n.º 1
0
def family_env_columns():
    return [
        PkName('family'),
        PkName('trait'),
        PkBigname('name'),
        Text('value')
    ]
Exemplo n.º 2
0
 def __init__(self, idcol, idtable, name):
     id_ = PkNum(idcol)
     id_.set_fk(idtable)
     tagname = PkName('tag')
     tagname.set_fk('tagnames')
     tagval = Text('value')
     cols = [id_, tagname, tagval]
     Table.__init__(self, name, cols)
Exemplo n.º 3
0
 def __init__(self, suite, traits_table):
     tablename = ujoin(suite, 'scripts')
     script_column = PkName('script')
     script_column.set_fk('scriptnames')
     sfile_column = Num('scriptfile')
     sfile_column.set_fk('textfiles')
     script_columns = [script_column, sfile_column]
     _TraitRelation.__init__(self, traits_table, tablename, script_columns)
Exemplo n.º 4
0
 def __init__(self, suite, traits_table):
     tablename = ujoin(suite, 'scripts')
     script_column = PkName('script')
     script_column.set_fk('scriptnames')
     sfile_column = Num('scriptfile')
     sfile_column.set_fk('textfiles')
     script_columns = [script_column, sfile_column]
     _TraitRelation.__init__(self, traits_table, tablename, script_columns)
Exemplo n.º 5
0
 def __init__(self, profiles_table):
     profile_col = PkName('profile')
     profile_col.set_fk(profiles_table)
     trait_col = PkName('trait')
     name_col = PkBigname('name')
     value_col = Text('value')
     cols = [profile_col, trait_col, name_col, value_col]
     tablename = ujoin('profile', 'variables')
     Table.__init__(self, tablename, cols)
Exemplo n.º 6
0
 def __init__(self, mach_types_table):
     mtype_col = PkName('machine_type')
     mtype_col.set_fk(mach_types_table)
     trait_col = PkName('trait')
     name_col = PkBigname('name')
     value_col = Text('value')
     cols = [mtype_col, trait_col, name_col, value_col]
     tablename = ujoin('machine_type', 'variables')
     Table.__init__(self, tablename, cols)
Exemplo n.º 7
0
 def __init__(self, mach_types_table):
     mtype_col = PkName('machine_type')
     mtype_col.set_fk(mach_types_table)
     trait_col = PkName('trait')
     name_col = PkBigname('name')
     value_col = Text('value')
     cols = [mtype_col, trait_col, name_col, value_col]
     tablename = ujoin('machine_type', 'variables')
     Table.__init__(self, tablename, cols)
Exemplo n.º 8
0
 def __init__(self, profiles_table):
     profile_col = PkName('profile')
     profile_col.set_fk(profiles_table)
     trait_col = PkName('trait')
     name_col = PkBigname('name')
     value_col = Text('value')
     cols = [profile_col, trait_col, name_col, value_col]
     tablename = ujoin('profile', 'variables')
     Table.__init__(self, tablename, cols)
Exemplo n.º 9
0
 def __init__(self, name, mach_types_table, disks_table):
     mtype_col = PkName('machine_type')
     mtype_col.set_fk(mach_types_table)
     diskname_col = PkName('diskname')
     diskname_col.set_fk(disks_table)
     columns = [mtype_col, diskname_col, PkName('device')]
     Table.__init__(self, name, columns)
Exemplo n.º 10
0
 def __init__(self, profiles_table, traits_table):
     profile_col = PkName('profile')
     profile_col.set_fk(profiles_table)
     trait_col = PkName('trait')
     trait_col.set_fk(traits_table)
     ord_col = Num('ord')
     Table.__init__(self, 'profile_trait', [profile_col, trait_col, ord_col])
Exemplo n.º 11
0
 def __init__(self, machines_table):
     machine_col = PkName('machine')
     machine_col.set_fk(machines_table)
     family_col = PkName('family')
     family_col.set_fk('families')
     columns = [machine_col, family_col]
     Table.__init__(self, 'machine_family', columns)
Exemplo n.º 12
0
 def __init__(self, fs_table, disks_table):
     fs_col = PkName('filesystem')
     fs_col.set_fk(fs_table)
     diskname_col = PkName('diskname')
     diskname_col.set_fk(disks_table)
     columns = [fs_col, diskname_col]
     Table.__init__(self, 'filesystem_disks', columns)
Exemplo n.º 13
0
 def __init__(self, machines_table):
     machine_col = PkName('machine')
     machine_col.set_fk(machines_table)
     parent_col = PkName('parent')
     parent_col.set_fk(machines_table)
     columns = [machine_col, parent_col]
     Table.__init__(self, 'machine_parent', columns)
Exemplo n.º 14
0
def profile_columns():
    return [
        PkName('profile'),
        Name('suite'),
        Bigname('template'),
        Text('description')
    ]
Exemplo n.º 15
0
 def __init__(self):
     idcol = PkName('name')
     keyid = Name('keyid')
     keyid.constraint.unique = True
     data = Text('data')
     columns = [idcol, keyid, data]
     Table.__init__(self, 'archive_keys', columns)
Exemplo n.º 16
0
 def __init__(self, fs_table, mounts_table):
     fs_col = PkName('filesystem')
     fs_col.set_fk(fs_table)
     mnt_name_col = PkName('mnt_name')
     mnt_name_col.set_fk(mounts_table)
     ord_col = Num('ord')
     partition_column = Num('partition')
     columns = [fs_col, mnt_name_col, ord_col, partition_column]
     Table.__init__(self, 'filesystem_mounts', columns)
Exemplo n.º 17
0
def suite_columns():
    return [
        PkName('suite'),
        Bool('nonUS'),
        Bool('updates'),
        Bool('local'),
        Bool('common')
    ]
Exemplo n.º 18
0
 def __init__(self, suite, traits_table, packages_table):
     packs_column = PkBigname('package')
     packs_column.set_fk(packages_table)
     action_column = PkName('action')
     action_column.constraint.default = 'install'
     columns = [packs_column, action_column]
     tablename = ujoin(suite, 'trait', 'package')
     _TraitRelation.__init__(self, traits_table, tablename, columns)
Exemplo n.º 19
0
 def __init__(self):
     idcol = PkName('apt_id')
     uri = Bigname('uri')
     dist = Name('dist')
     sections = Bigname('sections')
     local_path = Bigname('local_path')
     columns = [idcol, uri, dist, sections, local_path]
     Table.__init__(self, 'apt_sources', columns)
Exemplo n.º 20
0
 def __init__(self, machines_table):
     machine_col = PkName('machine')
     machine_col.set_fk(machines_table)
     tablename = ujoin('machine', 'scripts')
     script_column = PkName('script')
     script_column.set_fk('scriptnames')
     sfile_column = Num('scriptfile')
     sfile_column.set_fk('textfiles')
     columns = [machine_col, script_column, sfile_column]
     Table.__init__(self, tablename, columns)
Exemplo n.º 21
0
 def __init__(self):
     columns = [
         PkName('suite'),
         Bool('nonUS'),
         Bool('updates'),
         Bool('local'),
         Bool('common')
     ]
     Table.__init__(self, 'suites', columns)
Exemplo n.º 22
0
 def __init__(self, suite, traits_table, packages_table):
     packs_column = PkBigname('package')
     if not os.environ.has_key('PAELLA_DB_NOPACKAGETABLES'):
         packs_column.set_fk(packages_table)
     action_column = PkName('action')
     action_column.constraint.default = 'install'
     columns = [packs_column, action_column]
     tablename = ujoin(suite, 'trait', 'package')
     _TraitRelation.__init__(self, traits_table, tablename, columns)
Exemplo n.º 23
0
def mounts_columns():
    return [
        PkName('mnt_name'),
        Name('mnt_point'),
        Name('fstype'),
        Name('mnt_opts'),
        Name('dump'),
        Name('pass')
    ]
Exemplo n.º 24
0
 def __init__(self, kernels_table, profiles_table, diskconfig_table):
     machine_col = PkName('machine')
     kernel_col = Name('kernel')
     kernel_col.set_fk(kernels_table)
     profile_col = Name('profile')
     profile_col.set_fk(profiles_table)
     diskconfig_col = Name('diskconfig')
     diskconfig_col.set_fk(diskconfig_table)
     columns = [machine_col, kernel_col, profile_col, diskconfig_col]
     Table.__init__(self, 'machines', columns)
Exemplo n.º 25
0
 def __init__(self):
     columns = [
         PkName('suite'),
         Name('os'),
         # the columns below aren't being used anymore
         Bool('nonUS'),
         Bool('updates'),
         Bool('local'),
         Bool('common')
     ]
     Table.__init__(self, 'suites', columns)
Exemplo n.º 26
0
 def __init__(self, machines_table):
     machine_col = PkName('machine')
     machine_col.set_fk(machines_table)
     family_col = PkName('family')
     family_col.set_fk('families')
     columns = [machine_col, family_col]
     Table.__init__(self, 'machine_family', columns)
Exemplo n.º 27
0
 def __init__(self, machines_table):
     machine_col = PkName('machine')
     machine_col.set_fk(machines_table)
     parent_col = PkName('parent')
     parent_col.set_fk(machines_table)
     columns = [machine_col, parent_col]
     Table.__init__(self, 'machine_parent', columns)
Exemplo n.º 28
0
 def __init__(self, fs_table, disks_table):
     fs_col = PkName('filesystem')
     fs_col.set_fk(fs_table)
     diskname_col = PkName('diskname')
     diskname_col.set_fk(disks_table)
     columns = [fs_col, diskname_col]
     Table.__init__(self, 'filesystem_disks', columns)
Exemplo n.º 29
0
 def __init__(self, name, mach_types_table, disks_table):
     mtype_col = PkName('machine_type')
     mtype_col.set_fk(mach_types_table)
     diskname_col = PkName('diskname')
     diskname_col.set_fk(disks_table)
     columns = [mtype_col, diskname_col, PkName('device')]
     Table.__init__(self, name, columns)
Exemplo n.º 30
0
 def __init__(self, profiles_table, traits_table):
     profile_col = PkName('profile')
     profile_col.set_fk(profiles_table)
     trait_col = PkName('trait')
     trait_col.set_fk(traits_table)
     ord_col = Num('ord')
     Table.__init__(self, 'profile_trait', [profile_col, trait_col, ord_col])
Exemplo n.º 31
0
 def __init__(self, mach_types_table, kernels_table, profiles_table,
              filesystem_table):
     machine_col = PkName('machine')
     mtype_col = Name('machine_type')
     mtype_col.set_fk(mach_types_table)
     kernel_col = Name('kernel')
     kernel_col.set_fk(kernels_table)
     profile_col = Name('profile')
     profile_col.set_fk(profiles_table)
     fs_col = Name('filesystem')
     fs_col.set_fk(filesystem_table, 'filesystem')
     columns = [machine_col, mtype_col, kernel_col, profile_col, fs_col]
     Table.__init__(self, 'machines', columns)
Exemplo n.º 32
0
 def __init__(self, fs_table, mounts_table):
     fs_col = PkName('filesystem')
     fs_col.set_fk(fs_table)
     mnt_name_col = PkName('mnt_name')
     mnt_name_col.set_fk(mounts_table)
     ord_col = Num('ord')
     partition_column = Num('partition')
     columns = [fs_col, mnt_name_col, ord_col, partition_column]
     Table.__init__(self, 'filesystem_mounts', columns)
Exemplo n.º 33
0
 def __init__(self, mach_types_table):
     mtype_col = PkName('machine_type')
     mtype_col.set_fk(mach_types_table)
     tablename = ujoin('machine_type', 'scripts')
     script_column = PkName('script')
     script_column.set_fk('scriptnames')
     sfile_column = Num('scriptfile')
     sfile_column.set_fk('textfiles')
     script_columns = [mtype_col, script_column, sfile_column]
     Table.__init__(self, tablename, script_columns)
Exemplo n.º 34
0
 def __init__(self, mach_types_table):
     mtype_col = PkName('machine_type')
     mtype_col.set_fk(mach_types_table)
     fcol = PkName('family')
     fcol.set_fk('families')
     Table.__init__(self, 'machine_type_family', [mtype_col, fcol])
Exemplo n.º 35
0
 def __init__(self, name, disks_table):
     diskname_col = PkName('diskname')
     diskname_col.set_fk(disks_table)
     columns = [diskname_col] + partition_columns()
     Table.__init__(self, name, columns)
Exemplo n.º 36
0
def currentenv_columns():
    return [PkName('hostname'), PkBigname('name'), Text('value')]
Exemplo n.º 37
0
 def __init__(self, name, mach_types_table):
     mtype_col = PkName('machine_type')
     mtype_col.set_fk(mach_types_table)
     columns = [mtype_col, PkName('module'), Num('ord')]
     Table.__init__(self, name, columns)
Exemplo n.º 38
0
 def __init__(self):
     pcol = PkName('profile')
     pcol.set_fk('profiles')
     fcol = PkName('family')
     fcol.set_fk('families')
     Table.__init__(self, 'profile_family', [pcol, fcol])
Exemplo n.º 39
0
 def __init__(self, mach_types_table):
     mtype_col = PkName('machine_type')
     mtype_col.set_fk(mach_types_table)
     pcol = PkName('parent')
     pcol.set_fk(mach_types_table)
     Table.__init__(self, 'machine_type_parent', [mtype_col, pcol])
Exemplo n.º 40
0
def trait_columns():
    return [PkName('trait'), Text('description')]
Exemplo n.º 41
0
 def __init__(self, suite, traits_table):
     parent_column = PkName('parent')
     parent_column.set_fk(traits_table, 'trait')
     columns = [parent_column]
     tablename = ujoin(suite, 'trait', 'parent')
     _TraitRelation.__init__(self, traits_table, tablename, columns)
Exemplo n.º 42
0
 def __init__(self):
     idcol = PkName('name')
     diskconf_col = Text('content')
     disklist_col = Text('disklist')
     columns = [idcol, diskconf_col, disklist_col]
     Table.__init__(self, 'diskconfig', columns)
Exemplo n.º 43
0
def defaultenv_columns():
    return [PkName('section'), PkBigname('option'), Text('value')]
Exemplo n.º 44
0
 def __init__(self):
     idcol = PkName('script')
     typecol = Name('type')
     cols = [idcol, typecol]
     Table.__init__(self, 'scriptnames', cols)
Exemplo n.º 45
0
 def __init__(self, suite, traits_table):
     parent_column = PkName('parent')
     parent_column.set_fk(traits_table, 'trait')
     columns = [parent_column]
     tablename = ujoin(suite, 'trait', 'parent')
     _TraitRelation.__init__(self, traits_table, tablename, columns)
Exemplo n.º 46
0
 def __init__(self, traits_table, tablename, other_columns):
     RelationalTable.__init__(self, tablename, traits_table,
                              PkName('trait'), other_columns)
Exemplo n.º 47
0
 def __init__(self, name='kernels'):
     kernel_column = PkName('kernel')
     columns = [kernel_column]
     Table.__init__(self, name, columns)
Exemplo n.º 48
0
 def __init__(self, mounts_table):
     mnt_name_col = PkName('mnt_name')
     mnt_name_col.set_fk(mounts_table)
     partition_col = Num('partition')
     columns = [mnt_name_col, partition_col]
     Table.__init__(self, 'partition_mounts', columns)
Exemplo n.º 49
0
 def __init__(self):
     fcol = PkName('family')
     fcol.set_fk('families')
     pcol = PkName('parent')
     pcol.set_fk('families')
     Table.__init__(self, 'family_parent', [fcol, pcol])
Exemplo n.º 50
0
 def __init__(self):
     magnet = PkName('magnet')
     magnet.set_fk('magnets')
     troubleid = Num('troubleid')
     troubleid.set_fk('troubles')
     Table.__init__(self, 'trouble_magnets', [magnet, troubleid])