-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Server resets connection with no data? #1
Comments
Did you set up SSL as well? If so, please set |
Since I included "INSECURE_USE_HTTP=false", then SSL shouldn't be needed, however I did, indeed, setup SSL with a proper cert. I did include the port into the BASE_URL. Here's my env from start.sh (API secret and password xxx'ed out, of course): export SSL_KEY=/home/raj/.acme.sh/rajlinux.mojostan.us/rajlinux.mojostan.us.key environment variablesexport NODE_ENV="development" export PUMP_FIELDS="reservoir battery status" export TIME_FORMAT=24 Yes, I'm using a 192.168/24 network address, but at this time I'm only expecting this to work inside my house. The hostname "rajlinux.mojostan.us" agrees with that IP address as does the cert. Do you know of some way to turn on additional logging/debugging so that maybe I can see why it's closing the connection without doing anything? I looked through a lot of the code and don't see any additional debugging which could be turned on. Thanks for your help! |
Hmmm. Ok, setting the port to 443, and removing "export INSECURE_USE_HTTP=true", seems to make it work! Apparently, "INSECURE_USE_HTTP=true" doesn't actually work and the site MUST use SSL! Good to know! Sorry for having bothered you! |
If you can paste your nginx configuration, I would be very grateful. |
Sorry, I'm using it standalone on a separate port without nginx/apache. Maybe @rajid ? |
@rajid |
Sorry for taking a while to reply. This issue was opened a long time back and I've moved on to other things since then. I needed to find the computer (a small Raspberry Pi) and get it back onto the net. Looking at my start.sh, it looks to me as though I'm running standalone as well. It simply invokes "node" with "server.js". "ps" doesn't show nginx or apache and I don't see them in /etc/init.d. Maybe I'm missing something. Here's my start.sh (passwords removed, of course): #!/usr/bin/bash export SSL_KEY=/home/raj/.acme.sh/nightscout.mojostan.us/nightscout.mojostan.us.key environment variablesexport DISPLAY_UNITS="mg/dl" export PUMP_FIELDS="reservoir battery status" export TIME_FORMAT=24 start servernode --no-deprecation server.js |
@rajid Ok, thanks. I have configured it now. But port 443 is not used directly, because this port is occupied by our k8s. The https configuration is not enabled in the start.sh file. environment variablesexport DISPLAY_UNITS="mmol" S1 服务器远程连接 mongodexport MONGO_CONNECTION="mongodb://admin:[email protected]:27017/Nightscout" export HOSTNAME="127.0.0.1" export DEVICESTATUS_ADVANCED="true" 配置插件export ENABLE="delta direction upbat devicestatus dbsize ar2 careportal iob food cob openaps pump bwg rawbg basal" nginx.conf configuration file The problem I have now is: I visit ns.xxx.com/profile?token=admin-xxxxxxx Therefore, how should I configure my nginx? I did not find any relevant solutions on the Internet. |
I followed these instructions to install a nightscout/mongodb site on a small Linux system I have (v20.04 LTS). The mondodb installed with no problems and the "start.sh" script starts up the site just fine with no errors. I configured it into "development" mode hoping to get some more logging, but that doesn't show anything. I see "Listening on port 80 null" and I can see (with "netstat -an" that it's, indeed, listening. When I try to connect, the connection is just reset and dropped! I tried from various browsers and even using "curl" on the system itself. The /etc/hostname is set as the same hostname as that used in BASE_URL. I even set "INSECURE_USE_HTTP=false" to try to reduce the things which could go wrong. Still, no logging of anything when I connect and no output. Any ideas?
The text was updated successfully, but these errors were encountered: