Commit 39606850 authored by David Mondou's avatar David Mondou
Browse files

Removed debug messsages.

Renamed server.
parent 6b1f7155
......@@ -663,7 +663,7 @@ def enableOneTimeSetup(persist):
subprocess.call("/etc/init.d/dnsmasq start &> /dev/null", shell=True)
subprocess.call("ifconfig wlan0 192.168.0.50 netmask 255.255.255.0", shell=True)
subprocess.call("/usr/rigado/scripts/led_control.sh red solid", shell=True)
subprocess.call("/etc/init.d/oobe_server start", shell=True)
subprocess.call("/etc/init.d/iot-gateway-setup-server start", shell=True)
myssid = getSSID()
......@@ -683,7 +683,7 @@ def disableOneTimeSetup(persist):
subprocess.call("ifup wlan0", shell=True)
subprocess.call("/etc/init.d/dnsmasq stop &> /dev/null", shell=True)
subprocess.call("/usr/rigado/scripts/led_control.sh green solid", shell=True)
subprocess.call("/etc/init.d/oobe_server stop", shell=True)
subprocess.call("/etc/init.d/iot-gateway-setup-server stop", shell=True)
def toggleOneTimeSetup(persist):
if showWiFiMode() == "Master":
......
......@@ -70,7 +70,7 @@ function getContentType(filename) {
function injectStatus(in_text, statusmsg, iserr) {
var injectStatusAt = in_text.indexOf(injectStatusAfter) + injectStatusAfter.length;
var status = "";
console.log("START HERE")
if (statusmsg) {
if (iserr){
status = '<div id="statusarea" name="statusarea" class="status errmsg">' + '</div>';
......@@ -124,8 +124,6 @@ function setHost(params) {
}
function setWiFi(params) {
console.log("setWiFi");
var exec_cmd = "", errmsg = "Unknown error occurred.", exec_args=[];
if (!params.newwifi) {
......@@ -184,8 +182,6 @@ function doSleep() {
}
function runCmd(i, commands) {
console.log("Running commands")
console.log(i);
if (i === commands.length)
return;
......@@ -303,10 +299,8 @@ function inWhiteList(path) {
console.log(BIN_DIR+'/configure_gateway --showWiFiMode');
if ((result.code != 0) || ((typeof result.stdout !== 'undefined') && (result.stdout.trim() === "Master"))) {
return true;
} else {
console.log(" Result:");
console.log(JSON.stringify(result, null, 2));
}
return WHITELIST_PATHS[path] || WHITELIST_CMDS[path];
}
......@@ -333,7 +327,7 @@ function requestHandler(req, res) {
console.log(urlobj.pathname);
var result = shell.exec(BIN_DIR+'/configure_gateway --showWiFiMode', {silent:true});
console.log(BIN_DIR+'/configure_gateway --showWiFiMode')
console.log(result);
if ((result.code != 0) || ((typeof result.output !== 'undefined') && (result.output.trim() != "Master"))) {
var res_str = fs.readFileSync(site + '/status.html', {encoding: 'utf8'});
var myhostname, myipaddr;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment