From 257eb0c174ef2fdaa2015975c5919979afa8da90 Mon Sep 17 00:00:00 2001 From: Sol Jerome Date: Tue, 4 Nov 2014 09:57:08 -0600 Subject: Options.py: Fix database OPTIONS parsing Instead of parsing key/value pairs from bcfg2.conf, this allows the setting of the literal value which is then passed through to django as the value of the OPTIONS setting. This change allows for setting arbitrary options since some settings require nested dictionaries, etc. Signed-off-by: Sol Jerome --- doc/man/bcfg2.conf.txt | 5 ++--- doc/releases/1.3.6.txt | 7 +++++++ doc/server/database.txt | 4 ++-- 3 files changed, 11 insertions(+), 5 deletions(-) (limited to 'doc') diff --git a/doc/man/bcfg2.conf.txt b/doc/man/bcfg2.conf.txt index 6faf48a1a..f55540968 100644 --- a/doc/man/bcfg2.conf.txt +++ b/doc/man/bcfg2.conf.txt @@ -736,9 +736,8 @@ control the database connection of the server. Port for database connections. Not used for sqlite3. options - Various options for the database connection. The value is - expected as multiple key=value pairs, separated with commas. - The concrete value depends on the database engine. + Various options for the database connection. The value expected + is the literal value of the django OPTIONS setting. Reporting options ----------------- diff --git a/doc/releases/1.3.6.txt b/doc/releases/1.3.6.txt index e27b102bf..757fbf6f5 100644 --- a/doc/releases/1.3.6.txt +++ b/doc/releases/1.3.6.txt @@ -22,6 +22,13 @@ This is primarily a bugfix release. * Reporting: better exception handling * Various interrupt handling fixes * Fix client decision whitelist/blacklist handling +* Fix database OPTIONS parsing + + This change requires you to set the *options* value of the + ``[database`` section in ``bcfg2.conf`` to the literal value which is + passed through to the django OPTIONS setting. + + https://docs.djangoproject.com/en/1.7/ref/settings/#std:setting-OPTIONS Special thanks to the following contributors for this release: Michael Fenn, Matt Kemp, Alexander Sulfrian, Jonathan Billings. diff --git a/doc/server/database.txt b/doc/server/database.txt index 3c8970f68..15c66754f 100644 --- a/doc/server/database.txt +++ b/doc/server/database.txt @@ -51,8 +51,8 @@ of ``/etc/bcfg2.conf``. +-------------+------------------------------------------------------------+-------------------------------+ | options | Extra parameters to use when connecting to the database. | None | | | Available parameters vary depending on your database | | -| | backend. The parameters are supplied as comma separated | | -| | key=value pairs. | | +| | backend. The parameters are supplied as the value of the | | +| | django OPTIONS setting. | | +-------------+------------------------------------------------------------+-------------------------------+ -- cgit v1.2.3-1-g7c22