Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Oryx did npm run build but not using build folder #449

Closed
robi-ng opened this issue Dec 18, 2019 · 3 comments
Closed

Oryx did npm run build but not using build folder #449

robi-ng opened this issue Dec 18, 2019 · 3 comments

Comments

@robi-ng
Copy link

robi-ng commented Dec 18, 2019

Hi,
I'm trying to deploy react app to Azure App Service Linux instance. It's using Microsoft Oryx in the deployment, and correctly executing "npm run build" to generate React production files and copy all the files to /home/site/wwwroot, however the web server is not using the "build" folder to serve content. How can I configure it to use the "build" folder? (default React production folder)

@arroyc
Copy link
Contributor

arroyc commented Dec 26, 2019

Hi @robi-ng thanks for reporting, will you be please able to provide little more context? From your description my primary assumption is we need to configure the app so that it knows where is the "build" folder. Can you please verify if "build" folder resides in /home/site/wwwroot. Also it would be nice if you can share a sample repro app for this issue.

@robi-ng
Copy link
Author

robi-ng commented Dec 27, 2019

Hi @arroyc yes "build" folder resides in /home/site/wwwroot. I found the option on Azure portal, Configuration > General settings > Startup Command, to configure my startup command "npx serve -s build" so that it doesn't use the default "npm start" (meant for React development environment).

@robi-ng robi-ng closed this as completed Dec 27, 2019
@arroyc
Copy link
Contributor

arroyc commented Dec 27, 2019

Thank you for sharing @robi-ng .. hopefully things are resolved at your end .. please let us know for any future issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants