tarina

git clone https://git.tarina.org/tarina
Log | Files | Refs | README | LICENSE

commit 8d0ebd38d862dfbac06f5795e138f1d5818910a3
parent 52fe813691315b34180589a3ff7dfa0c5e1827ee
Author: rbckman <robinbackman@gmail.com>
Date:   Fri, 10 Aug 2018 18:58:48 +0300

server starts on boot

Diffstat:
Asrv/static/Videos | 2++
Msrv/tarinaserver.py | 8++++++++
Mtarina.py | 3+++
3 files changed, 13 insertions(+), 0 deletions(-)

diff --git a/srv/static/Videos b/srv/static/Videos @@ -0,0 +1 @@ +/home/pi/Videos/+ \ No newline at end of file diff --git a/srv/tarinaserver.py b/srv/tarinaserver.py @@ -1,6 +1,14 @@ +#!/usr/bin/python + import web import os +# Get path of the current dir, then use it as working directory: +rundir = os.path.dirname(__file__) +if rundir != '': + os.chdir(rundir) + +# Link video directory to static dir os.system("ln -s /home/pi/Videos static/Videos") films = [] diff --git a/tarina.py b/tarina.py @@ -1172,6 +1172,9 @@ def main(): #call ([tarinafolder + '/fbcp &'], shell = True) call (['./startinterface.sh &'], shell = True) + #Start tarinaserver on port 80 + call (['./srv/tarinaserver.py 80 &'], shell = True) + #LOAD FILM AND SCENE SETTINGS try: camera.brightness, camera.contrast, camera.saturation, camera.shutter_speed, camera.iso, camera.awb_mode, camera.awb_gains, awb_lock, miclevel, headphoneslevel, filmfolder, filmname, scene, shot, take, thefile, beeps, flip, renderscene, renderfilm = loadfilmsettings(filmfolder, filmname)