DEV Community

Discussion on: Docker, Django, React: Building Assets and Deploying to Heroku

Collapse
 
englishcraig profile image
Craig Franklin

Instead of running a separate Webpack server to send the React code to the browser, we build the React code into an optimised code bundle in the Dockerfile. The Django server can then send the React code files to the browser via WhiteNoise. So, we only need the one container/process for the Django server.

Collapse
 
eddyojb profile image
eddy-ojb

With some tweaks I have successfully deployed this on Azure. Thanks Craig.

Collapse
 
eddyojb profile image
eddy-ojb

That sounds amazing. I'll try it out.