I need to pass an environment variable to node like below.
RAZZLE_ENV=production node build/server.js
How I can achieve this with docker CMD command. My current config is like this:
CMD [ 'node', 'build/server.js' ]
I did change it to this:
CMD [ 'RAZZLE_ENV=production node', 'build/server.js' ]
But it does not work as expected and the container is not going to be created even.
UPDATE: the error is:
Cannot find module /app/RAZZLE_ENV=production node