Rocket.Chat push notifications not working - remoteIP wrong
-
I am running my instance of Rocket.Chat and still have not managed to get the push notifications working.
Around one month ago, I have opened a thread in the RC forum, because I thought the error i got was more relied to their side. As I am not getting an answer there, I decided to link this one here as well.
So I have set up my RC instance and I registered it on RC Cloud.
The Push Gateway is enabled and set to https://gateway.rocket.chat/.
I installed the RC apps on an iPhone, an android phone as well as on my Macbook. Finally I also managed to send test-push-notifications via the dedicated button. It tells me that it has successfully sent a test notification to 1 device. However, having checked the settings and permissions on the phones, I to not receive any notification on either of them.
When I look at the Log I can see two suspicious entries. What is the remoteIP? The VM of the RC is NATed by a firewall and does have a dedicated public IP, which is obviously not the remoteIP. May that be the problem? How could I change this?
{"level":35,"time":"2021-11-01T09:15:10.813Z","pid":1,"hostname":"ca5sdgh54-1a8d-4564-b816-8d3e5edffd65","name":"API","method":"POST","url":"/api/v1/method.call/push_test","userId":"So49htrw","userAgent":"Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0","length":"87","host":"rocketchat.foobar.com","referer":"https://rocketchat.foobar.com/admin/Push",**"remoteIP":"172.16.115.1"**,"status":200,"responseTime":67} {"level":50,"time":"2021-11-01T09:15:11.118Z","pid":1,"hostname":"ca35684-1a484-b816-8d3e5d65","name":"Push","msg":"Error sending push to gateway (0 try) -> {\"response\":{\"statusCode\":404,\"content\":\"404 page not found\",\"headers\":{\"access-control-allow-headers\":\"Content-Type, Authorization, Content-Length, X-Requested-With\",\"access-control-allow-methods\":\"GET, PUT, POST, DELETE, OPTIONS\",\"access-control-allow-origin\":\"*\",\"access-control-expose-headers\":\"Content-Type, Authorization, Cache-Control, Expires, Pragma, X-powered-by\",\"cache-control\":\"private, no-cache, no-store, must-revalidate\",\"content-length\":\"18\",\"content-type\":\"text/plain\",\"date\":\"Mon, 01 Nov 2021 09:15:11 GMT\",\"expires\":\"-1\",\"pragma\":\"no-cache\",\"x-powered-by\":\"Rocket Fuel and Rocketeers\",\"connection\":\"close\"},\"data\":null}}"}The second entry I do not understand is this…
{"level":50,"time":"2021-11-01T09:11:15.118Z","pid":1,"hostname":"ca54-b816-8d3edffd65","name":"Push","msg":"Error sending push to gateway (4 try) -> {\"response\":{\"statusCode\":404,\"content\":\"404 page not found\",\"headers\":{\"access-control-allow-headers\":\"Content-Type, Authorization, Content-Length, X-Requested-With\",\"access-control-allow-methods\":\"GET, PUT, POST, DELETE, OPTIONS\",\"access-control-allow-origin\":\"*\",\"access-control-expose-headers\":\"Content-Type, Authorization, Cache-Control, Expires, Pragma, X-powered-by\",\"cache-control\":\"private, no-cache, no-store, must-revalidate\",\"content-length\":\"18\",\"content-type\":\"text/plain\",\"date\":\"Mon, 01 Nov 2021 09:11:15 GMT\",\"expires\":\"-1\",\"pragma\":\"no-cache\",\"x-powered-by\":\"Rocket Fuel and Rocketeers\",\"connection\":\"close\"},\"data\":null}}"} {"level":30,"time":"2021-11-01T09:11:15.119Z","pid":1,"hostname":"ca5e0f54-1a4d-4594-b816-8d3e5edffd65","name":"Push","msg":"Trying sending push to gateway again in 960000 'milliseconds'"}Follow the thread here:
https://forums.rocket.chat/t/getting-push-notifications-to-work/12513Thanks in advance!
-
I am running my instance of Rocket.Chat and still have not managed to get the push notifications working.
Around one month ago, I have opened a thread in the RC forum, because I thought the error i got was more relied to their side. As I am not getting an answer there, I decided to link this one here as well.
So I have set up my RC instance and I registered it on RC Cloud.
The Push Gateway is enabled and set to https://gateway.rocket.chat/.
I installed the RC apps on an iPhone, an android phone as well as on my Macbook. Finally I also managed to send test-push-notifications via the dedicated button. It tells me that it has successfully sent a test notification to 1 device. However, having checked the settings and permissions on the phones, I to not receive any notification on either of them.
When I look at the Log I can see two suspicious entries. What is the remoteIP? The VM of the RC is NATed by a firewall and does have a dedicated public IP, which is obviously not the remoteIP. May that be the problem? How could I change this?
{"level":35,"time":"2021-11-01T09:15:10.813Z","pid":1,"hostname":"ca5sdgh54-1a8d-4564-b816-8d3e5edffd65","name":"API","method":"POST","url":"/api/v1/method.call/push_test","userId":"So49htrw","userAgent":"Mozilla/5.0 (Windows NT 10.0; rv:91.0) Gecko/20100101 Firefox/91.0","length":"87","host":"rocketchat.foobar.com","referer":"https://rocketchat.foobar.com/admin/Push",**"remoteIP":"172.16.115.1"**,"status":200,"responseTime":67} {"level":50,"time":"2021-11-01T09:15:11.118Z","pid":1,"hostname":"ca35684-1a484-b816-8d3e5d65","name":"Push","msg":"Error sending push to gateway (0 try) -> {\"response\":{\"statusCode\":404,\"content\":\"404 page not found\",\"headers\":{\"access-control-allow-headers\":\"Content-Type, Authorization, Content-Length, X-Requested-With\",\"access-control-allow-methods\":\"GET, PUT, POST, DELETE, OPTIONS\",\"access-control-allow-origin\":\"*\",\"access-control-expose-headers\":\"Content-Type, Authorization, Cache-Control, Expires, Pragma, X-powered-by\",\"cache-control\":\"private, no-cache, no-store, must-revalidate\",\"content-length\":\"18\",\"content-type\":\"text/plain\",\"date\":\"Mon, 01 Nov 2021 09:15:11 GMT\",\"expires\":\"-1\",\"pragma\":\"no-cache\",\"x-powered-by\":\"Rocket Fuel and Rocketeers\",\"connection\":\"close\"},\"data\":null}}"}The second entry I do not understand is this…
{"level":50,"time":"2021-11-01T09:11:15.118Z","pid":1,"hostname":"ca54-b816-8d3edffd65","name":"Push","msg":"Error sending push to gateway (4 try) -> {\"response\":{\"statusCode\":404,\"content\":\"404 page not found\",\"headers\":{\"access-control-allow-headers\":\"Content-Type, Authorization, Content-Length, X-Requested-With\",\"access-control-allow-methods\":\"GET, PUT, POST, DELETE, OPTIONS\",\"access-control-allow-origin\":\"*\",\"access-control-expose-headers\":\"Content-Type, Authorization, Cache-Control, Expires, Pragma, X-powered-by\",\"cache-control\":\"private, no-cache, no-store, must-revalidate\",\"content-length\":\"18\",\"content-type\":\"text/plain\",\"date\":\"Mon, 01 Nov 2021 09:11:15 GMT\",\"expires\":\"-1\",\"pragma\":\"no-cache\",\"x-powered-by\":\"Rocket Fuel and Rocketeers\",\"connection\":\"close\"},\"data\":null}}"} {"level":30,"time":"2021-11-01T09:11:15.119Z","pid":1,"hostname":"ca5e0f54-1a4d-4594-b816-8d3e5edffd65","name":"Push","msg":"Trying sending push to gateway again in 960000 'milliseconds'"}Follow the thread here:
https://forums.rocket.chat/t/getting-push-notifications-to-work/12513Thanks in advance!
@opensourced I tried this on Android.
I thought registering the server in the initial setup screen made things work but it didn't. What I had to do was:
-
Administration->Connectivity Services. On top right, click Cloud console:

-
Then, I registered a new account there with my email. Verified the email. I then created a selfhosted instances to got a "token" which I had to put in the UI above.
-
After that, I
Administration->Pushand clicked onSend a test push to my user. That did not work. -
Restarted the app
-
Administration->Pushand clicked onSend a test push to my user. That worked. I gotThis is a push test messagenotification.
-
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login