persistent lws store

master
lza_menace 2 years ago
parent 8795d8c9eb
commit 9d7827b28a

2
.gitignore vendored

@ -1,5 +1,5 @@
monero-lws
docker-monero-node
.env
data
node_modules

@ -5,6 +5,8 @@ x-log-config: &log-config
options:
max-size: "50m"
max-file: "5"
volumes:
lws:
services:
# lws-web:
# container_name: lws-web
@ -41,6 +43,8 @@ services:
ports:
- 127.0.0.1:8081:8081
- 127.0.0.1:8080:8080
volumes:
- lws:/home/monero-lws/.bitmonero/light_wallet_server
command:
--scan-threads 4 --rest-threads 4 --rest-server http://0.0.0.0:8080 --admin-rest-server http://0.0.0.0:8081 --log-level 1 --daemon=tcp://monerod:18082 --sub=tcp://monerod:18083 --confirm-external-bind
<<: *log-config

@ -2,12 +2,11 @@ from datetime import datetime
import requests
from peewee import *
from playhouse.sqliteq import SqliteQueueDatabase
from lws import config
db = SqliteQueueDatabase('data/lws-web.db')
db = SqliteDatabase('data/lws.db')
class User(Model):
@ -111,7 +110,7 @@ class Wallet(Model):
req = requests.post(endpoint, json=data, timeout=5)
req.raise_for_status()
if req.ok:
print(r.content)
print(req.content)
return True
return False
except Exception as e:

Loading…
Cancel
Save