]> git.decadent.org.uk Git - dak.git/blobdiff - dak/generate_releases.py
dak/generate_releases.py: pull components from the database
[dak.git] / dak / generate_releases.py
index 8d3635e2e2b9fb611ed4784befc1d39d26a3f21a..03081627dd27df5e29a0df2e0e61d5b5e0b20e53 100755 (executable)
@@ -173,9 +173,7 @@ class ReleaseWriter(object):
 
         out.write("Architectures: %s\n" % (" ".join([a.arch_string for a in architectures])))
 
-        ## FIXME: Components need to be adjusted to whatever will be in the db
-        ## Needs putting in the DB
-        components = ['main', 'contrib', 'non-free']
+        components = [ c.component_name for c in session.query(Component) ]
 
         out.write("Components: %s\n" % ( " ".join(map(lambda x: "%s%s" % (suite_suffix, x), components ))))
 
@@ -312,6 +310,7 @@ def main ():
         usage()
 
     Logger = daklog.Logger('generate-releases')
+    pool = DakProcessPool()
 
     session = DBConn().session()
 
@@ -332,8 +331,6 @@ def main ():
 
     broken=[]
 
-    pool = DakProcessPool()
-
     for s in suites:
         # Setup a multiprocessing Pool. As many workers as we have CPU cores.
         if s.untouchable and not Options["Force"]: