wip: it wants tables

This commit is contained in:
teutat3s 2023-05-22 19:26:55 +02:00
parent b5365ffb3c
commit e39cb5308f
Signed by: teutat3s
GPG key ID: 4FA1D3FA524F22C1
2 changed files with 12 additions and 9 deletions

View file

@ -31,22 +31,25 @@
};
runErpNext = pkgs.writeShellScriptBin "runErpNext" ''
export PYTHON_PATH=${penv}/${py.sitePackages}
hostname=localhost
sites=$(mktemp -d)
for f in ${assets}/share/sites/*; do
ln -s "$f" "$sites/$(basename $f)"
done
cat >$sites/common_site_config.json <<EOF
{
"db_host": "foo",
"db_port": 1336,
"db_name": "foo" ,
"redis_cache": "foo",
"redis_queue": "foo",
"redis_socketio": "foo",
"socketio_port": 6732,
"maintenance_mode": true
"db_host": "localhost",
"db_port": 3306,
"db_name": "erpnext" ,
"db_password": "erpnext" ,
"redis_cache": "redis://localhost",
"redis_queue": "redis://localhost",
"redis_socketio": "redis://localhost",
"socketio_port": 6379
}
EOF
mkdir -p $sites/$hostname/logs
ln -s $sites/common_site_config.json $sites/$hostname/site_config.json
echo "Sites dir: $sites"
${penv}/bin/gunicorn --chdir="$sites" --bind=0.0.0.0:9090 --threads=4 --workers=2 --worker-class=gthread --worker-tmp-dir=/dev/shm --timeout=120 --preload frappe.app:application
'';

View file

@ -48,7 +48,7 @@ let
yarnFlags = [ "--production" ];
offlineCache = fetchYarnDeps {
yarnLock = "${erpnextSrc}/yarn.lock";
yarnLock = "${src}/yarn.lock";
hash = "sha256-PBdMUz9gJIoQaqQYbdk+xnd8CyZPmdeyz/9WznCb4Ss=";
};