bandwidthd (2.0.1+cvs20090917-4.1) 81_phpdbconfig.dpatch

Summary

 phphtdocs/config.conf |    7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

    
download this patch

Patch contents

#! /bin/sh /usr/share/dpatch/dpatch-run
## 81_phpdbconfig.dpatch by Andreas Henriksson <andreas@fatal.se>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: Modify php configuration to fetch postgresql auth params from
## DP: dbconfig-common generated file.

@DPATCH@
diff -urNad bandwidthd-2.0.1+cvs20071208~/phphtdocs/config.conf bandwidthd-2.0.1+cvs20071208/phphtdocs/config.conf
--- bandwidthd-2.0.1+cvs20071208~/phphtdocs/config.conf	2007-09-04 22:14:25.000000000 +0200
+++ bandwidthd-2.0.1+cvs20071208/phphtdocs/config.conf	2007-12-08 21:55:48.000000000 +0100
@@ -1,4 +1,4 @@
-<?
+<?php
 define("DFLT_WIDTH", 1100);
 define("DFLT_HEIGHT", 325);
 define("DFLT_INTERVAL", INT_DAILY);
@@ -7,5 +7,6 @@
 define("ZOOM_LAT", "40.72982797782921");
 define("ZOOM_LEVEL", "8");
 
-$db_connect_string = "host = 216.24.112.16 user = swarm dbname = swarm"
-?>
\ No newline at end of file
+include("/etc/bandwidthd/debian-db.php");
+$db_connect_string = "host='$dbserver' port='$dbport' dbname='$dbname' user='$dbuser' password='$dbpass'";
+?>