CC-2579: Upgrad fails 1.8->1.9
- moved all the config files to each upgrade dir - also fixed back up name of 1.9.0 conifg to 1.9.0(from 1.8.1)
This commit is contained in:
parent
d1494c1735
commit
a84cb7fc37
9 changed files with 5 additions and 10 deletions
|
@ -9,14 +9,12 @@
|
|||
require_once(dirname(__FILE__).'/../../include/AirtimeIni.php');
|
||||
require_once(dirname(__FILE__).'/../../include/AirtimeInstall.php');
|
||||
|
||||
|
||||
/**
|
||||
* This function creates the /etc/airtime configuration folder
|
||||
* and copies the default config files to it.
|
||||
*/
|
||||
function CreateIniFiles()
|
||||
{
|
||||
global $AIRTIME_SRC;
|
||||
global $AIRTIME_PYTHON_APPS;
|
||||
|
||||
if (!file_exists("/etc/airtime/")){
|
||||
|
@ -26,7 +24,7 @@ function CreateIniFiles()
|
|||
}
|
||||
}
|
||||
|
||||
if (!copy($AIRTIME_SRC."/build/airtime.conf.170", CONF_FILE_AIRTIME)){
|
||||
if (!copy("airtime.conf.170", CONF_FILE_AIRTIME)){
|
||||
echo "Could not copy airtime.conf to /etc/airtime/. Exiting.";
|
||||
exit(1);
|
||||
}
|
||||
|
|
|
@ -59,7 +59,6 @@ foreach ($configFiles as $conf) {
|
|||
*/
|
||||
function CreateIniFiles()
|
||||
{
|
||||
global $AIRTIME_SRC;
|
||||
global $AIRTIME_PYTHON_APPS;
|
||||
|
||||
if (!file_exists("/etc/airtime/")){
|
||||
|
@ -69,7 +68,7 @@ function CreateIniFiles()
|
|||
}
|
||||
}
|
||||
|
||||
if (!copy($AIRTIME_SRC."/build/airtime.conf.180", CONF_FILE_AIRTIME)){
|
||||
if (!copy("airtime.conf.180", CONF_FILE_AIRTIME)){
|
||||
echo "Could not copy airtime.conf to /etc/airtime/. Exiting.";
|
||||
exit(1);
|
||||
}
|
||||
|
|
|
@ -112,7 +112,6 @@ function LoadConfig($CC_CONFIG) {
|
|||
*/
|
||||
function CreateIniFiles()
|
||||
{
|
||||
global $AIRTIME_SRC;
|
||||
global $AIRTIME_PYTHON_APPS;
|
||||
|
||||
if (!file_exists("/etc/airtime/")){
|
||||
|
@ -122,7 +121,7 @@ function CreateIniFiles()
|
|||
}
|
||||
}
|
||||
|
||||
if (!copy($AIRTIME_SRC."/build/airtime.conf.181", CONF_FILE_AIRTIME)){
|
||||
if (!copy("airtime.conf.181", CONF_FILE_AIRTIME)){
|
||||
echo "Could not copy airtime.conf to /etc/airtime/. Exiting.";
|
||||
exit(1);
|
||||
}
|
||||
|
|
|
@ -112,7 +112,6 @@ function LoadConfig($CC_CONFIG) {
|
|||
*/
|
||||
function CreateIniFiles()
|
||||
{
|
||||
global $AIRTIME_SRC;
|
||||
global $AIRTIME_PYTHON_APPS;
|
||||
|
||||
if (!file_exists("/etc/airtime/")){
|
||||
|
@ -122,7 +121,7 @@ function CreateIniFiles()
|
|||
}
|
||||
}
|
||||
|
||||
if (!copy($AIRTIME_SRC."/build/airtime.conf.182", CONF_FILE_AIRTIME)){
|
||||
if (!copy("airtime.conf.182", CONF_FILE_AIRTIME)){
|
||||
echo "Could not copy airtime.conf to /etc/airtime/. Exiting.";
|
||||
exit(1);
|
||||
}
|
||||
|
|
|
@ -462,7 +462,7 @@ class AirtimeIni{
|
|||
AirtimeIni::CONF_FILE_LIQUIDSOAP);
|
||||
|
||||
// Backup the config files
|
||||
$suffix = date("Ymdhis")."-1.8.1";
|
||||
$suffix = date("Ymdhis")."-1.9.0";
|
||||
foreach ($configFiles as $conf) {
|
||||
if (file_exists($conf)) {
|
||||
echo "Backing up $conf to $conf$suffix.bak".PHP_EOL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue