From b580a7be73982198c07b8dbcf606fb493c0a198b Mon Sep 17 00:00:00 2001 From: James Date: Tue, 8 Jan 2013 12:31:14 -0500 Subject: [PATCH] CC-4812: Property "off_air_meta" will block airtime-liquidsoap to start - fixed --- .../application/models/StreamSetting.php | 7 +++++++ python_apps/pypo/install/pypo-initialize.py | 21 ------------------- 2 files changed, 7 insertions(+), 21 deletions(-) diff --git a/airtime_mvc/application/models/StreamSetting.php b/airtime_mvc/application/models/StreamSetting.php index 2ea1e0830..f7ecab761 100644 --- a/airtime_mvc/application/models/StreamSetting.php +++ b/airtime_mvc/application/models/StreamSetting.php @@ -201,6 +201,13 @@ class Application_Model_StreamSetting "value"=>self::getDjLiveStreamMountPoint(), "type"=>"string"); } + + $sql = "SELECT *" + ." FROM cc_pref" + ." WHERE keystr = 'off_air_meta'"; + + $out = $con->query($sql)->fetchAll(); + $rows[] = array("keyname" => $out[0]["keystr"], "value"=>$out[0]["valstr"], "type"=>"string"); return $rows; } diff --git a/python_apps/pypo/install/pypo-initialize.py b/python_apps/pypo/install/pypo-initialize.py index af12ff02e..6581eef72 100644 --- a/python_apps/pypo/install/pypo-initialize.py +++ b/python_apps/pypo/install/pypo-initialize.py @@ -38,27 +38,6 @@ def get_os_codename(): return ("unknown", "unknown") -def generate_liquidsoap_config(ss): - data = ss['msg'] - fh = open('/etc/airtime/liquidsoap.cfg', 'w') - fh.write("################################################\n") - fh.write("# THIS FILE IS AUTO GENERATED. DO NOT CHANGE!! #\n") - fh.write("################################################\n") - for d in data: - buffer = d[u'keyname'] + " = " - if(d[u'type'] == 'string'): - temp = d[u'value'] - buffer += '"%s"' % temp - else: - temp = d[u'value'] - if(temp == ""): - temp = "0" - buffer += temp - buffer += "\n" - fh.write(api_client.encode_to(buffer)) - fh.write('log_file = "/var/log/airtime/pypo-liquidsoap/