Basically, put the lines below on the Apache config file (httpd.conf)
<VirtualHost *:80>
ProxyRequests Off
ProxyErrorOverride Off
ProxyPass /react-app http://localhost:3000/
ProxyPassReverse /react-app http://localhost:3000/
</VirtualHost>
- the /react-app folder should reside at htdocs and the app should be running at http://localhost:3000/
- to access, simply go to localhost:80/react-app
- 80 is the port Apache is running on
After editing the Apache config file, need to explicitly write the code for the correct bundle.js
on the index.html file since the original bundle.js will result in 404
example: <script src="http://localhost/react-app/static/js/bundle.js"></script>
(recommended to be placed after body tags)