Tell us what’s happening:
I’m able to get a correct JSON response, but outside repl my solution doesn’t seem to be registering properly (as in when I host it on my own domain). It also works in the browser.
Thanks for the reply.
It’s hosted in EC2.
It’s currently running again, I’ll leave it up this time(I did a nuke and pave to rule out cruft from a previous project on the same instance). It should be accessible from anywhere (groups are 0.0.0.0/0). I’m able to curl from another ec2 instance in a separate VPC:
However, did you use the boilerplate from freecodecamp or did you remove some parts? The thing is, the tests have some endpoints where they check for some things, hence if you removed them or didn’t use the boilerplate, you won’t be able to pass:
for the purposes of troubleshooting, it’s just a RHEL8 Linux VPS. So FCC can’t/won’t test over HTTP, and I need to install some LetsEncrypt certificates or something, if I understand correctly. Why wouldn’t FCC be able to do an unencrypted GET against my domain?
I didn’t shut it down, but the process did indeed die. I’ve brought it back up.
[ec2-user@ip-172-31-14-229 boilerplate-express]$ nohup npm start &
[ec2-user@ip-172-31-14-229 boilerplate-express]$ nohup: ignoring input and appending output to ‘nohup.out’
[ec2-user@ip-172-31-14-229 boilerplate-express]$ netstat -tulpn | grep 3000
(Not all processes could be identified, non-owned process info
will not be shown, you would have to be root to see it all.)
tcp6 0 0 :::3000 :::* LISTEN 2743/node