remove unnecessary install code for saas
This commit is contained in:
parent
3b9b23a7dd
commit
ab5639ef79
|
@ -41,17 +41,6 @@ try:
|
||||||
if not os.path.exists(PATH_INI_FILE):
|
if not os.path.exists(PATH_INI_FILE):
|
||||||
shutil.copy('%s/../media-monitor.cfg'%current_script_dir, PATH_INI_FILE)
|
shutil.copy('%s/../media-monitor.cfg'%current_script_dir, PATH_INI_FILE)
|
||||||
|
|
||||||
# load config file
|
|
||||||
try:
|
|
||||||
config = ConfigObj(PATH_INI_FILE)
|
|
||||||
config['rabbitmq_user'] = os.environ['RABBITMQ_USER']
|
|
||||||
config['rabbitmq_password'] = os.environ['RABBITMQ_PASSWORD']
|
|
||||||
config['rabbitmq_vhost'] = os.environ['RABBITMQ_VHOST']
|
|
||||||
config.write()
|
|
||||||
except Exception, e:
|
|
||||||
print 'Error loading config file: ', e
|
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
#copy monit files
|
#copy monit files
|
||||||
shutil.copy('%s/../../monit/monit-airtime-generic.cfg'%current_script_dir, '/etc/monit/conf.d/')
|
shutil.copy('%s/../../monit/monit-airtime-generic.cfg'%current_script_dir, '/etc/monit/conf.d/')
|
||||||
subprocess.call('sed -i "s/\$admin_pass/%s/g" /etc/monit/conf.d/monit-airtime-generic.cfg' % get_rand_string(), shell=True)
|
subprocess.call('sed -i "s/\$admin_pass/%s/g" /etc/monit/conf.d/monit-airtime-generic.cfg' % get_rand_string(), shell=True)
|
||||||
|
|
|
@ -78,17 +78,6 @@ try:
|
||||||
os.chown("/etc/airtime", -1, gid)
|
os.chown("/etc/airtime", -1, gid)
|
||||||
os.chmod("/etc/airtime", stat.S_IRUSR | stat.S_IWUSR | stat.S_IXUSR | stat.S_IRGRP | stat.S_IWGRP | stat.S_IXGRP | stat.S_IROTH | stat.S_IXOTH)
|
os.chmod("/etc/airtime", stat.S_IRUSR | stat.S_IWUSR | stat.S_IXUSR | stat.S_IRGRP | stat.S_IWGRP | stat.S_IXGRP | stat.S_IROTH | stat.S_IXOTH)
|
||||||
|
|
||||||
# load config file
|
|
||||||
try:
|
|
||||||
config = ConfigObj(PATH_INI_FILE)
|
|
||||||
config['rabbitmq_user'] = os.environ['RABBITMQ_USER']
|
|
||||||
config['rabbitmq_password'] = os.environ['RABBITMQ_PASSWORD']
|
|
||||||
config['rabbitmq_vhost'] = os.environ['RABBITMQ_VHOST']
|
|
||||||
config.write()
|
|
||||||
except Exception, e:
|
|
||||||
print 'Error loading config file: ', e
|
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
#copy monit files
|
#copy monit files
|
||||||
shutil.copy('%s/../../monit/monit-airtime-generic.cfg'%current_script_dir, '/etc/monit/conf.d/')
|
shutil.copy('%s/../../monit/monit-airtime-generic.cfg'%current_script_dir, '/etc/monit/conf.d/')
|
||||||
subprocess.call('sed -i "s/\$admin_pass/%s/g" /etc/monit/conf.d/monit-airtime-generic.cfg' % get_rand_string(), shell=True)
|
subprocess.call('sed -i "s/\$admin_pass/%s/g" /etc/monit/conf.d/monit-airtime-generic.cfg' % get_rand_string(), shell=True)
|
||||||
|
|
Loading…
Reference in New Issue