-
Notifications
You must be signed in to change notification settings - Fork 0
/
notes.txt
51 lines (40 loc) · 1.81 KB
/
notes.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
add projects from github?
portfolio:
what have i done?
what do i want to do next?
add json.parse and invalid packet handling
add software log
add links to sites like contact, about, github, linkedin, etc
finish the drawingboard app
add NEW USER to start the node apps and SEE IPTABLES ADVICE.txt
use nmap security suite
add SEO metadata
configure MONGODB ports, auth, backup!
sine-wave timing game
JESUS APP
prettyify blog
local storage app
add json.parse and invalid packet handling
add software log
add links to sites like contact, about, github, linkedin, etc
finish the drawingboard app
improve content server usability
edit posts
more, sensible links
investigate DDOS protection
try to hack the system
cross-site scripting
packet sniffing
beautify grokking equanimity
use emoji font for a frogger style game
Port 80
What I do on my cloud instances is I redirect port 80 to port 3000 with this command:
sudo iptables -t nat -A PREROUTING -i eth0 -p tcp --dport 80 -j REDIRECT --to-port 3000
Then I launch my Node.js on port 3000. Requests to port 80 will get mapped to port 3000.
You should also edit your /etc/rc.local file and add that line minus the sudo. That will add the redirect when the machine boots up. You don't need sudo in /etc/rc.local because the commands there are run as root when the system boots.
Logs
Use the forever module to launch your Node.js with. It will make sure that it restarts if it ever crashes and it will redirect console logs to a file.
Launch on Boot
Add your Node.js start script to the file you edited for port redirection, /etc/rc.local. That will run your Node.js launch script when the system starts.
Digital Ocean & other VPS
This not only applies to Linode, but Digital Ocean, AWS EC2 and other VPS providers as well. However, on RedHat based systems /etc/rc.local is /ect/rc.d/local.