From 2cb7c0f8da4fcaf452f32feefae2a05cfcee36e0 Mon Sep 17 00:00:00 2001 From: Patrick McDonagh Date: Thu, 14 Apr 2016 15:42:44 -0500 Subject: [PATCH] Fix file names for git repo --- init/tagserver | 2 +- init/website | 40 --------------------------------------- python/tag_mysql.py | 2 +- python/tagserver_MySQL.py | 2 +- 4 files changed, 3 insertions(+), 43 deletions(-) delete mode 100755 init/website diff --git a/init/tagserver b/init/tagserver index a9de9b3..14d5c0c 100755 --- a/init/tagserver +++ b/init/tagserver @@ -19,7 +19,7 @@ case "$1" in echo "Starting loggers" kill -9 $(cat /root/tagserver.pid) # run application you want to start - /usr/bin/python /root/tagserver/python/tagserver_SQLite.py > /dev/null 2>&1 & echo $! > "/root/tagserver.pid" + /usr/bin/python /root/tagserver/python/tag-server_MySQL.py > /dev/null 2>&1 & echo $! > "/root/tagserver.pid" ;; stop) diff --git a/init/website b/init/website deleted file mode 100755 index 55f8d21..0000000 --- a/init/website +++ /dev/null @@ -1,40 +0,0 @@ -#! /bin/sh -# /etc/init.d/website - -### BEGIN INIT INFO -# Provides: website -# Required-Start: $remote_fs $syslog -# Required-Stop: $remote_fs $syslog -# Default-Start: 2 3 4 5 -# Default-Stop: 0 1 6 -# Short-Description: Simple script to start a program at boot -# Description: A simple script from www.stuffaboutcode.com which will start / stop a program a boot / shutdown. -### END INIT INFO - -# If you want a command to always run, put it here - -# Carry out specific functions when asked to by the system -case "$1" in - start) - echo "Starting website" - # run application you want to start - # /home/pi/runWebsite.sh - if [ $(ps aux | grep $USER | grep node | grep -v grep | wc -l | tr -s "\n") -eq 0 ] - then - export NODE_ENV=production - export PATH=/usr/local/bin:$PATH - forever start /home/poconsole/tagserver/www/app.js > /dev/null - fi -;; - stop) - echo "Stopping website" - # kill application you want to stop - forever stopall - ;; - *) - echo "Usage: /etc/init.d/website {start|stop}" - exit 1 - ;; -esac - -exit 0 diff --git a/python/tag_mysql.py b/python/tag_mysql.py index ed468d2..9719b7e 100644 --- a/python/tag_mysql.py +++ b/python/tag_mysql.py @@ -8,7 +8,7 @@ import micro800 as u800 import traceback import pickle -with open('/root/tagserver/python/mysql_cfg.pickle', 'rb') as cfgFile: +with open('/root/tag-server/python/mysql_cfg.pickle', 'rb') as cfgFile: mysql_cfg = pickle.load(cfgFile) con = mysqlcon.connect(**mysql_cfg) diff --git a/python/tagserver_MySQL.py b/python/tagserver_MySQL.py index f85a9b5..4812868 100644 --- a/python/tagserver_MySQL.py +++ b/python/tagserver_MySQL.py @@ -12,7 +12,7 @@ from tag_mysql import Tag import traceback import time -with open('/root/tagserver/python/mysql_cfg.pickle', 'rb') as pickleconfig: +with open('/root/tag-server/python/mysql_cfg.pickle', 'rb') as pickleconfig: mysql_cfg = pickle.load(pickleconfig) if mysql_cfg: