Merge branch 'master' of 192.168.0.2:photoassistant
This commit is contained in:
2
README
2
README
@@ -2,7 +2,7 @@ In here we can put instructions on how to run this / any general info
|
||||
|
||||
|
||||
ubuntu packages:
|
||||
sudo apt-get install -y mediainfo cmake
|
||||
sudo apt-get install -y mediainfo cmake python3-flask
|
||||
|
||||
pip packages:
|
||||
* pymediainfo
|
||||
|
||||
1
TODO
1
TODO
@@ -42,6 +42,7 @@
|
||||
clear all jobs (via GUI)
|
||||
clear old jobs? (via b/end?)
|
||||
clear FE messages (at least dup ones on File data deletion) -- in backend
|
||||
need to copy into here the jquery/fa files so we don't need internet to function
|
||||
|
||||
sorter...
|
||||
need some way to multiselect images [DONE]
|
||||
|
||||
5
main.py
5
main.py
@@ -6,7 +6,7 @@ from flask_bootstrap import Bootstrap
|
||||
from wtforms import SubmitField, StringField, HiddenField, SelectField, IntegerField, TextAreaField, validators
|
||||
from flask_wtf import FlaskForm
|
||||
from status import st, Status
|
||||
from shared import CreateSelect
|
||||
from shared import CreateSelect, DB_URL
|
||||
import re
|
||||
import socket
|
||||
|
||||
@@ -17,9 +17,6 @@ print( "Running on: {}".format( hostname) )
|
||||
app = Flask(__name__)
|
||||
### what is this value? I gather I should change it?
|
||||
|
||||
# connection string: pguseraccount, pgpasswd, mara as the host, db port is 55432, dbname
|
||||
DB_URL = 'postgresql+psycopg2://pa:for_now_pa@mara.ddp.net:55432/pa'
|
||||
|
||||
app.config['SQLALCHEMY_DATABASE_URI'] = DB_URL
|
||||
app.config['SQLALCHEMY_TRACK_MODIFICATIONS'] = False
|
||||
app.config.from_mapping( SECRET_KEY=b'\xd6\x04\xbdj\xfe\xed$c\x1e@\xad\x0f\x13,@G')
|
||||
|
||||
@@ -1,13 +1,18 @@
|
||||
import socket
|
||||
|
||||
DB_URL = 'postgresql+psycopg2://pa:for_now_pa@mara.ddp.net:55432/pa'
|
||||
hostname = socket.gethostname()
|
||||
PROD_HOST="pa_web"
|
||||
|
||||
if hostname == PROD_HOST:
|
||||
PA_JOB_MANAGER_HOST="192.168.0.2"
|
||||
DB_URL = 'postgresql+psycopg2://pa:for_now_pa@192.168.0.2:55432/pa'
|
||||
elif hostname == "lappy":
|
||||
PA_JOB_MANAGER_HOST="localhost"
|
||||
DB_URL = 'postgresql+psycopg2://pa:for_now_pa@localhost:5432/pa'
|
||||
else:
|
||||
PA_JOB_MANAGER_HOST="localhost"
|
||||
DB_URL = 'postgresql+psycopg2://pa:for_now_pa@mara.ddp.net:55432/pa'
|
||||
|
||||
PA_JOB_MANAGER_PORT=55430
|
||||
|
||||
THUMBSIZE=256
|
||||
|
||||
Reference in New Issue
Block a user