use db in ~, add apache config
This commit is contained in:
parent
7ae717ad7b
commit
fd1c0e8dfa
@ -28,6 +28,8 @@ from sqlalchemy.orm import relationship, backref
|
||||
from sqlalchemy.orm import sessionmaker
|
||||
from sqlalchemy import create_engine
|
||||
|
||||
from xdg.BaseDirectory import save_data_path
|
||||
|
||||
Base = declarative_base()
|
||||
|
||||
class Request(Base):
|
||||
@ -82,7 +84,7 @@ class LibReport(Base):
|
||||
t_updated = Column(DateTime, default=datetime.now, onupdate=datetime.now)
|
||||
|
||||
def db_engine():
|
||||
return create_engine('sqlite:///abichecker.db')
|
||||
return create_engine('sqlite:///%s/abichecker.db'%save_data_path('opensuse.org', 'abichecker'))
|
||||
|
||||
def db_session():
|
||||
engine = db_engine()
|
||||
|
10
abichecker/apache/abichecker.conf
Normal file
10
abichecker/apache/abichecker.conf
Normal file
@ -0,0 +1,10 @@
|
||||
<VirtualHost *:80>
|
||||
ServerName abichecker.suse.de
|
||||
|
||||
WSGIDaemonProcess abichecker user=_opensuse-abichecker group=nogroup display-name=%{GROUP} home=/usr/share/osc-plugin-factory/abichecker
|
||||
WSGIProcessGroup abichecker
|
||||
|
||||
WSGIScriptAlias / /usr/share/osc-plugin-factory/abichecker/abichecker-web.py
|
||||
</VirtualHost>
|
||||
|
||||
# vim: syntax=apache sw=4 et
|
Loading…
x
Reference in New Issue
Block a user