Ok so I've given this a go... I have it running on a Pi 4b. I'm at the point to make the node app a service so it'll start automatically. Where I'm really stuck is adding a second FTP server to the config.js in /Importer/api. I have tried a bunch of different comma separated lines and I get an error running the import. It is successful on the first one but fails on the second every time.
Importer/api/Config.js relevant ftpServers block.
IP is the same Windows machine running multiple game servers with IIS pointing the FTP sites to different ports. I can connect to each via FTP (FileZilla) separately but the Importer cannot. Can you nudge me in the right direction to get this to work? It's been over 20 years since I worked with a *nix OS regularly so barney-style will be helpful.
Code: Select all
ftpServers: [
{"host": "192.168.x.x", "port": 21, "user": "Username", "password": "pass"},
{"host": "192.168.x.x", "port": 31, "user": "Username", "password": "pass"}
//{"host": "127.0.0.1", "port": 21, "user": "scott", "password": "password"},
],
Code: Select all
$ node app
[22:34:59][Start Up]: --------------------------------------------------
[22:34:59][Start Up]: --------------------------------------------------
[22:34:59][Start Up]: ------- Node UTStats Import Module Started -------
[22:34:59][Start Up]: ---------- Created by Scott Adkin ----------------
[22:34:59][Start Up]: ---------- Build April 2020 ----------------------
[22:34:59][Start Up]: ---- To change settings go to /api/config.js -----
[22:34:59][Start Up]: --------------------------------------------------
New LogParser
┌─────────┬────────────┐
│ (index) │ Values │
├─────────┼────────────┤
│ 0 │ 'Imported' │
└─────────┴────────────┘
┌─────────┐
│ (index) │
├─────────┤
└─────────┘
[22:34:59][Success]: Connected to 192.168.x.x:21 successfully!
/home/pi/Node-UTStats-master/Importer/api/ftpimporter.js:61
if(err) throw err;
^
Error: The system cannot find the file specified.
at makeError (/home/pi/Node-UTStats-master/Importer/node_modules/ftp/lib/connection.js:1067:13)
at Parser.<anonymous> (/home/pi/Node-UTStats-master/Importer/node_modules/ftp/lib/connection.js:113:25)
at Parser.emit (events.js:198:13)
at Parser._write (/home/pi/Node-UTStats-master/Importer/node_modules/ftp/lib/parser.js:59:10)
at doWrite (_stream_writable.js:415:12)
at writeOrBuffer (_stream_writable.js:399:5)
at Parser.Writable.write (_stream_writable.js:299:11)
at Socket.ondata (/home/pi/Node-UTStats-master/Importer/node_modules/ftp/lib/connection.js:273:20)
at Socket.emit (events.js:198:13)
at addChunk (_stream_readable.js:288:12)