I want to achieve: Start Rails in EC2 production environment
This is my second month studying Ruby and Rails.
We are currently building an EC2 server.
After bundle install Unicorn
In EC2, execute the following command to reflect the contents of GitHub on EC2.
[ec2-user @ ip-***-**-**-***<repository name>] $git pull origin master
[ec2-user @ ip-***-**-**-***<repository name>] $rails db: create RAILS_ENV = production
When I execute, the following error occurs.
Corresponding source code
Could not find kgio-2.11.3 in any of the sources Run `bundle install` to install missing gems.
group: production do gem'unicorn', '5.4.1' end
What I tried
production: <<: * default database: username: root password:<% = ENV ['DATABASE_PASSWORD']%> socket: /var/lib/mysql/mysql.sock
I didn't have a question in the same situation as myself when I googled, so I haven't tried anything concrete yet.
I was wondering if I should install a gem called kgio, but when I checked the Ruby Gem documentation (https://rubygems.org/gems/kgio/versions/2.11.3), "kgio is Ruby2.3. I didn't know if I could install it because there was an explanation such as "It can only be used after that." .. ..
Please provide more detailed information here.
If i have any missing information or conditions, I will add it, so please.
It's not enough words, but I would appreciate it if you could answer. Thank you.
Answer # 1
$bundle installI think you need.
$rails db: create RAILS_ENV = production
In the argument of rails
RAILS_ENV = productionThe method of passing is deprecated.
$RAILS_ENV = production rails db: createYou will use either of them.
- ruby on rails - webpacker cannot be compiled
- ruby on rails 5 - rails cannot retrieve params data
- ruby on rails - data cannot be saved in the intermediate table (parameters cannot be passed)
- ruby - [rails] the cart function cannot get the cart id associated with the user
- ruby on rails - the image cannot be saved in s3 and cannot be displayed in the view aws :: sigv4 :: errors :: missingcredentials
- ruby - apprb cannot be started is there a problem with require'sinatra'? ?? ??
- ruby on rails - getting started with rails testing with rspec 2 setting up rspec after git clone, add gem and bundle install wit
- ruby on rails - cannot save nested child model
- ruby on rails - about matters that cannot be migrated
- ruby on rails - bootstap 4 does not work in rails6 production environment
- ruby on rails - cannot start unicorn cannot load `railsconfigactive_storageservice`
- ruby on rails - image cannot be saved (activestorage installed) null in image of table
- ruby on rails - [aws production environment] regarding http error 406
- ruby on rails - you cannot change the keychain after downloading the pem file when creating an ec2 instance the matter that come
- ruby - i started the server in rails s but can't open it
- ruby on rails - [aws/ec2] when i try to run a rails application in a production environment, an error occurs in the image displa
- ruby on rails 5 - actioncontroller :: invalidauthenticitytoken cannot be resolved
- ruby on rails - syntax error cannot be resolved
- ruby on rails - i cannot save a comment on the comment posting page
- ruby - behavior that i do not know if rails can be started with unicorn
- ruby - it works fine in my local environment, but when i deploy it to aws, i get an error in mysql2 :: error: unknown column
- ruby - unable to deploy on capistrano
- ruby - passing variables using render partial
- ruby - output the total integer value held by each user
- html - i can't set the regular expression well
- ruby - rails i want to make the created_at time the same when creating multiple data at once
- ruby - dynamic form implementation in nested_form