We want to run both development
and production
instances on elastic beanstalk for our rails app.
Characteristics of production
are:
Database requirements (none on eb instance):
development
currently uses sqlite on eb instance development
and production
Our development
is currently a t1.micro
, and clearly that isn't going to cut it even for development (login sometimes takes 60 seconds).
I will experiment, but would appreciate if anyone has any quick bits of advice for choosing an appropriate instance type for each env and which criteria/constraints are most meaningful for rails ie compute units.
My 2 cents - lean on the side of CPU over memory. CPU always helps; at the very least your app will compile assets and load into memory faster on deploys. I suggest starting with 2x c1.medium in production (in 2 different AZs for basic redundancy) and 1x m1.small in development.
Don't overthink the machine sizes, instead get the low hanging fruit right, namely: put your static assets on a CDN and implement fragment caching (stored in a dedicated redis or memcached node per environment).
If you've never done this before, New Relic Pro will likely give you a big head start identifying bottlenecks in your app.
Then get to load testing!
Also, please don't share your RDS instance between production and development. Isolate the two environments by giving each their own database.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.