Accessing environment variables from Go for Serverless Api
I have a go API setup using Serverless. In my root directory I have main.go
and .env
, as well as a config
folder which contains config.go
. I’m having issues as my attempts to access the endpoint throws a runtime error due to it being unable to access the environment variables once deployed (works fine locally).