pelith / node-eauth-server

An OAuth-compatiable service based on Ethereum credentials to authenticate users on a website. See live version at https://eauth.pelith.com/ https://forum.hakka.finance

Home Page:https://eauth.app

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fields with spaces in dotenv

opened this issue · comments

Dotenv files commonly contain string literals with spaces due to bash field splitting. The typical format of an env file to prevent bash field splitting is to wrap the string with spaces like:

EAUTH_BANNER="Some Long String"
EAUTH_MESSAGE_PREFIX="Authenticate with your MetaMask wallet" 

In contract.js the above format causes issues when reading with process.env as the result is "Some long string" and not Some long string. I propose to add some handling logic in contract.js to handle this common case for better interoperability with bash scripts.

commented

EAUTH_MESSAGE_PREFIX="Authenticate with your MetaMask wallet" is for Docker Compose v2.
EAUTH_MESSAGE_PREFIX=Authenticate with your MetaMask wallet is for Docker Compose v1.