Custom Query (894 matches)

Filters
 
Or
 
  
 
Columns

Show under each result:


Results (85 - 87 of 894)

Ticket Owner Reporter Resolution Summary
#148 desai [email protected] fixed bcfg2 fails to build config if Base/ directory is empty
Description

I've enabled the Base Plugin as structure in my bcfg2.conf file.

My Base/ directory in the repository is empty.

$ bcfg2-info
...
> build myhostname config.txt
error in GetStructures
Traceback (most recent call last):
  File "/usr/lib/python2.4/site-packages/Bcfg2/Server/Core.py", line 300, in BuildConfiguration
    structures = self.GetStructures(meta)
  File "/usr/lib/python2.4/site-packages/Bcfg2/Server/Core.py", line 263, in GetStructures
    [struct.BuildStructures(metadata) for struct in self.structures])
  File "/usr/lib/python2.4/site-packages/Bcfg2/Server/Plugins/Base.py", line 29, in BuildStructures
    [base.Match(metadata) for base in self.entries.values()])
TypeError: reduce() of empty sequence with no initial value

After creating an empty file Base/test.xml bcfg2-info is able to produce a config file for the specified host.

#158 desai [email protected] fixed TCheetah: TemplateFile should only accept template files
Description

When FAM processes first the info file from the /Cheetah dir instead of the template file for a ConfigEntry?, the name argument of the TemplateFile? gets initialized with the epath ".../info" and line 29 won't work anymore since it assumes the name to end on '.../template' (self.name[:-8] in the code).

for line in open(self.name[:-8] + '/info').readlines():

Possible Fix:

Index: TCheetah.py
===================================================================
--- TCheetah.py (Revision 2330)
+++ TCheetah.py (Arbeitskopie)
@@ -97,7 +97,7 @@
         if action in ['exists', 'created']:
             if posixpath.isdir(epath):
                 self.AddDirectoryMonitor(epath[len(self.data):])
-            else:
+            elif event.filename == 'template':
                 if not self.entries.has_key(identifier):
                     self.entries[identifier] = TemplateFile(epath, self.properties)
                     self.Entries['ConfigFile'][identifier] = self.BuildEntry
#163 desai [email protected] fixed Make bcfg2.conf file accessible to the Plugins
Description

Wish: Make cfile in Core.py accessible to the Plugins ( i.e. Core.py, line 202 set self.cfile = ConfigParser?...). Would allow the Plugins to read own section entries (e.g. database connection config) from the bcfg.conf file.

Otherwise every Plugin would need to open himself the bcfg2.conf file.(?) Also the path to the bcfg2.conf file is not known within the Plugin class.(?)

Note: See TracQuery for help on using queries.