reput - Using Internal Address and Updating HTTP Status Code
jordan-wright opened this issue · 6 comments
Hey there!
Great work with reput
- your recommendation was a big driver in me finally purchasing a Remarkable, and I love it so far.
It's quite possible I'm doing something wrong on my end, just wanted to pass over some observations from using reput
with version 2.0.1.1:
- I showed the web server only listening on the internal
10.11.99.1
IP address:
remarkable: ~/ netstat -an | head
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address Foreign Address State
tcp 0 0 10.11.99.1:80 0.0.0.0:* LISTEN
As such, trying to upload via loopback failed.
- It appears that the result of the
/upload
endpoint for me is a 201, not a 200.
This issue isn't meant to be a request to fix anything, more or less passing along what I had to modify to get reput
working like a charm for me in case you run into similar issues.
Looks like 2.0 wasn't rolled out to my device yet. Good to know that it will not take significant changes!
Yep! Not too bad when it comes to changes. Anyway, since this is your mostly-harmless repo, I'll go ahead and close this out. Just wanted to give a heads up.
Have a good one!
I now got the 2.0 update, and I can't seem to enable the web interface. Did it work for you without connecting the USB cable?
I showed the web server only listening on the internal 10.11.99.1 IP address:
As such, trying to upload via loopback failed.
I'm still able to wget http://10.11.99.1
while SSHed into the reMarkable, and ssh -fNL 12345:10.11.99.1:80 root@WIFI.IP.ADDR.ESS
gives me a usable web interface on http://127.0.0.1:12435
on my laptop.
EDIT: Oh, but that internal IP is only up when usb0
is actually connected 😞
It looks like manually setting up the usb0 interface allows the web interface to be used without the device being plugged in:
ifconfig usb0 10.11.99.1 netmask 255.255.255.248 up
It appears to persist even when the device goes to sleep and is brought back up. Though, if you do plug it back in and unplug it, you'll need to re-run the command.