]> andersk Git - moira.git/blobdiff - gen/boot.pc
Include CUPS-PRINT servers in generated tftp config files, too.
[moira.git] / gen / boot.pc
index f7f127578bbd712d1f96184dec38f3c35a0945ac..79f12be66ada0df4459c992b10ce541aa22ed581 100644 (file)
@@ -58,13 +58,14 @@ int main(int argc, char **argv)
   EXEC SQL WHENEVER SQLERROR DO sqlerr();
 
   /* Get print spoolers for allow lists. */
-  EXEC SQL SELECT COUNT(service) INTO :alcount FROM serverhosts
-    WHERE service = 'PRINT';
+  EXEC SQL SELECT COUNT(service) INTO :alcount FROM serverhosts sh
+    WHERE sh.service = 'PRINT' or sh.service = 'CUPS-PRINT';
   allowlist = malloc(alcount * sizeof(*allowlist));
 
   EXEC SQL DECLARE csr_spool CURSOR FOR
     SELECT m.address, sh.value3 FROM machine m, serverhosts sh
-    WHERE m.mach_id = sh.mach_id AND sh.service = 'PRINT';
+    WHERE m.mach_id = sh.mach_id AND 
+    (sh.service = 'PRINT' OR sh.service = 'CUPS-PRINT');
   EXEC SQL OPEN csr_spool;
   for (i = 0; i < alcount; i++)
     {
This page took 0.033471 seconds and 4 git commands to generate.