Re: DVSwitch Dashboard Web Port


Steve N4IRS
 

Joe,
Interesting that webproxy was not running when it was showing with netstat.
As far as upgrading nodejs, you might look at: <https://github.com/nodesource/distributions>

curl -sL https://deb.nodesource.com/setup_15.x | sudo -E bash -
sudo apt-get install -y nodejs

I used it to upgrade a install of Stretch.

Glad you have it working.

Steve

On 12/9/20 10:28 PM, Joe, WB3IHY wrote:

Okay...problem (finally) solved.  Turns out that the problem was (probably) not related to changing the dashboard web port.  Documenting my experience so that others may benefit.

Steve, your suggestion to check for webproxy log started me on the trail: THERE WASN'T ONE! Which meant that the service wasn't running at all.

I then tried running the following command manually: sudo /usr/bin/node /opt/Web_Proxy/proxy.js 8080 2222 which generated a SyntaxError: "Unexpected token "Const { Exit }"

Much Googling told me earlier versions of node.js would do that.  Found out that, somehow, I had version (gasp) 4 installed for some reason! My other instances were running 8.10.0, so that had to be the culprit.  Much more Googling told me how to update it to the latest version (15.4.0 as of this writing):

First, install npm: sudo apt-get install npm
Then install n, a node version manager: sudo npm install -g n
Then install the latest version of node: sudo n latest
If the installer changed the path from what's specified in the webproxy service call, change it back with "PATH=$PATH"
Verify that node was truly updated with: node -v
Try running the service manually: sudo /usr/bin/node /opt/Web_Proxy/proxy.js 8080 2222
If you still get the same error, you might have to forcibly copy the newer binary to where the webproxy expects it to be: sudo cp /usr/local/n/versions/node/15.4.0/bin/node /usr/bin/node
Try running the service manually again.  If you get a "cannot find module "ws" " error, then do this: cd /opt/Web_Proxy/ and then install the ws module with sudo npm install ws
Try running the service manually again.  It should now run with no errors.  Control C out of it.  You're almost done.
Finally, start the service properly: sudo systemctl start webproxy.service

Voila: RX Monitor audio AT LAST!


Join main@DVSwitch.groups.io to automatically receive all group messages.