質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.48%
Cloud9

Cloud9は、クラウドからのプログラミングが可能になるWebサービス。IDEとしての機能が搭載されており、GitHubやHerokuなど他ツールとの連携も可能です。ブラウザ上で動くため、デバイスに関係なく開発環境を準備できます。

Ruby on Rails 5

Ruby on Rails 5は、オープンソースのWebアプリケーションフレームワークです。「同じことを繰り返さない」というRailsの基本理念のもと、他のフレームワークより少ないコードで簡単に開発できるよう設計されています。

Q&A

解決済

2回答

221閲覧

bundle installが通らない

hazu

総合スコア33

Cloud9

Cloud9は、クラウドからのプログラミングが可能になるWebサービス。IDEとしての機能が搭載されており、GitHubやHerokuなど他ツールとの連携も可能です。ブラウザ上で動くため、デバイスに関係なく開発環境を準備できます。

Ruby on Rails 5

Ruby on Rails 5は、オープンソースのWebアプリケーションフレームワークです。「同じことを繰り返さない」というRailsの基本理念のもと、他のフレームワークより少ないコードで簡単に開発できるよう設計されています。

0グッド

0クリップ

投稿2019/03/04 16:07

bundle installと入力すると以下のようなエラーがでます。

解決方法を教えてください。

ec2-user:~/environment/message-board $ bundle install Gem files will remain installed in /home/ec2-user/.rvm/gems/ruby-2.6.0/gems/mysql2-0.4.10 for inspection. Results logged to /home/ec2-user/.rvm/gems/ruby-2.6.0/extensions/x86_64-linux/2.6.0/mysql2-0.4.10/gem_make.out An error occurred while installing mysql2 (0.4.10), and Bundler cannot continue. Make sure that `gem install mysql2 -v '0.4.10' --source 'https://rubygems.org/'` succeeds before bundling. In Gemfile: mysql2

Gemfile

1source 'https://rubygems.org' 2 3git_source(:github) do |repo_name| 4 repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/") 5 "https://github.com/#{repo_name}.git" 6end 7 8 9# Bundle edge Rails instead: gem 'rails', github: 'rails/rails' 10gem 'rails', '~> 5.0.6' 11# Use mysql as the database for Active Record 12gem 'mysql2', '>= 0.3.18', '< 0.5' 13# Use Puma as the app server 14gem 'puma', '~> 3.0' 15# Use SCSS for stylesheets 16gem 'sass-rails', '~> 5.0' 17# Use Uglifier as compressor for JavaScript assets 18gem 'uglifier', '>= 1.3.0' 19# Use CoffeeScript for .coffee assets and views 20gem 'coffee-rails', '~> 4.2' 21# See https://github.com/rails/execjs#readme for more supported runtimes 22# gem 'therubyracer', platforms: :ruby 23 24# Use jquery as the JavaScript library 25gem 'jquery-rails' 26# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks 27gem 'turbolinks', '~> 5' 28# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder 29gem 'jbuilder', '~> 2.5' 30# Use Redis adapter to run Action Cable in production 31# gem 'redis', '~> 3.0' 32# Use ActiveModel has_secure_password 33# gem 'bcrypt', '~> 3.1.7' 34 35# Use Capistrano for deployment 36# gem 'capistrano-rails', group: :development 37 38group :development, :test do 39 # Call 'byebug' anywhere in the code to stop execution and get a debugger console 40 gem 'byebug', platform: :mri 41end 42 43group :development do 44 # Access an IRB console on exception pages or by using <%= console %> anywhere in the code. 45 gem 'web-console', '>= 3.3.0' 46 gem 'listen', '~> 3.0.5' 47 # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring 48 gem 'spring' 49 gem 'spring-watcher-listen', '~> 2.0.0' 50end 51 52# Windows does not include zoneinfo files, so bundle the tzinfo-data gem 53gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby] 54

Cloud9を使っています。

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

guest

回答2

0

ベストアンサー

gem install mysql2 -v '0.4.10' --source 'https://rubygems.org/
を実行してみたり、
/home/ec2-user/.rvm/gems/ruby-2.6.0/extensions/x86_64-linux/2.6.0/mysql2-0.4.10/gem_make.out
を見て、どんなエラーが起こっているかを確認してみてください。

投稿2019/03/04 21:58

katoy

総合スコア22324

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

0

sudo yum -y install mysql-devel

で解決できました。

投稿2019/03/05 02:47

hazu

総合スコア33

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.48%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問