-
-
Notifications
You must be signed in to change notification settings - Fork 631
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
Issues deploying to Elastic Beanstalk with Yarn #766
Comments
@chrisjones-tripletri Thanks for the kudos! I'll add your quote to KUDOS.md. Can you please submit a PR, adding a doc file /docs/additional-reading/elastic-beanstalk.md and reference that file in /SUMMARY.md (and maybe the README.md). |
Yes, I will do this this week. Thanks. |
@chrisjones-tripletri Did you get a chance to doc this? I'd like to get this issue closed. Thanks! |
Sorry this took so long. I have actually never done a pull request before, and I didn't know how, so I had to research it. I just submitted "Adding Documentation About Deploying to Elastic Beanstalk with Yarn #790". Hopefully I did it correctly enough. I am not sure I did it in a way that links back to this bug. |
Should close this now that the related patch is merged. |
I have used React on Rails several times and really appreciate it. Thanks for all your work. Historically, it would just deploy to AWS Elastic Beanstalk without issues. However, with the switch to Yarn, which is not installed on the AWS linux image, it no longer does.
I tried changing the config.npm_build_production_command, but that did not resolve the issue. In addition, I felt it was better to use the same package manager in dev and production.
After much fiddling around, I found that adding a yarn.config file in the .ebextensions folder resolved the issue:
I am certain there is some better, more concise way to achieve this, but I not an AWS expert. This worked for me.
Anyway, I thought it might be worth documenting here, in case other people are trying to deploy a react-on-rails app to Elastic Beanstalk.
Thanks for all your efforts! React on Rails was the first framework that enabled me to achieve really good results with a javascript/client-side app.
The text was updated successfully, but these errors were encountered: