Micro-service to save/load fiddles for NEAR Studio.
This micro-service depends on the following environment variables:
APP_URL-- defaulthttps://app.near.ai;CONTRACT_HELPER_URL-- defaulthttps://studio.nearprotocol.com/contract-api;NODE_URL-- defaulthttps://studio.nearprotocol.com/devnet;WALLET_URL-- defaulthttps://wallet.nearprotocol.com;
The above variables define the URLs used by the web apps from withing the browser so they should always correspond to public IP or DNS name.
NODE_ENV-- defaultproduction;PORT-- default3000;
- Install latest Node.js LTS release.
- Install postgres
brew install postgres
brew services start postgresql
createuser fiddle -W # It'll ask for password, enter "fiddle"
createdb -O fiddle fiddle
createdb -O fiddle fiddle_test
npm install
node app.js