Netlify environment variables not used during build process

I have a react app and set a netlify variable (REACT_APP_ENV). When I deploy via a git push, the variable isn’t set in the program. The results of

console.log(process.env.REACT_APP_ENV) yields undefined.

This project doesn’t use create_react_app. Is there something extra I need to do to get webpack to use these variables?

Thank you!

found the solution from this page:

updated dotenv to include systemvars key:

 plugins: [
    new Dotenv({
        systemvars: true
    })
  ]

Thanks so much for coming back and letting us know!! This will help future forums members who find themselves in the same position.

(post deleted by author)