Assuming npm is already installed, for a raspberry pi: (adapted from a post by VilifiedFerret.
npm i https://github.com/tonesto7/echo-speaks-server
sudo npm install -g pm2
cd node_modules/echo-speaks-server
sudo pm2 start index.js
sudo pm2 list
sudo pm2 save
sudo pm2 startup
sudo pm2 save
Once that is running you need to configure insert the callback url from the habitat echo-speaks config page into http://RPI_IP_ADDRESS:8091 in your browser, then go back to the habitat echo speaks page and login to the local server.
Logging into the Amazon account via the local server took multiple attempts, but worked eventually.