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

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

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

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

Docker

Dockerは、Docker社が開発したオープンソースのコンテナー管理ソフトウェアの1つです

Q&A

解決済

1回答

1097閲覧

Dockerでのデータベース作成

退会済みユーザー

退会済みユーザー

総合スコア0

Ruby on Rails 5

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

Docker

Dockerは、Docker社が開発したオープンソースのコンテナー管理ソフトウェアの1つです

0グッド

0クリップ

投稿2020/01/21 19:21

編集2020/01/21 22:15

Dockerでのデータベース作成について質問です。

bindex-0.8.1がないので実行できないとエラーがでてますが、インストールしても同じエラーが出てしまいます。
これはどのように対処すればいいでしょうか?

$ docker-compose run web bundle exec rake db:create Starting rails_db_1 ... done Could not find bindex-0.8.1 in any of the sources Run `bundle install` to install missing gems. $ gem install bindex -v "0.8.1" Temporarily enhancing PATH for MSYS/MINGW... Building native extensions. This could take a while... Successfully installed bindex-0.8.1 Parsing documentation for bindex-0.8.1 Installing ri documentation for bindex-0.8.1 Done installing documentation for bindex after 0 seconds 1 gem installed $ bundle install Using rake 13.0.1 . . . Bundle complete! 15 Gemfile dependencies, 62 gems now installed. Use `bundle info [gemname]` to see where a bundled gem is installed. bun $ bundle info bindex * bindex (0.8.1) Summary: Bindings for your Ruby exceptions Homepage: https://github.com/gsamokovarov/bindex Path: C:/Ruby25-x64/lib/ruby/gems/2.5.0/gems/bindex-0.8.1 $ docker-compose run web bundle exec rake db:create Starting rails_db_1 ... done Could not find bindex-0.8.1 in any of the sources Run `bundle install` to install missing gems.

追記:
Gemfileに以下を追記しbundle installをしても結果は同じでした。

gem 'bindex', '0.8.1'

Gemfile

gem 'sass-rails', '~> 5.0' # Use Uglifier as compressor for JavaScript assets gem 'uglifier', '>= 1.3.0' # Use CoffeeScript for .coffee assets and views gem 'coffee-rails', '~> 4.2' # See https://github.com/rails/execjs#readme for more supported runtimes # gem 'therubyracer', platforms: :ruby # Use jquery as the JavaScript library gem 'jquery-rails' # Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks gem 'turbolinks', '~> 5' # Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder gem 'jbuilder', '~> 2.5' # Use Redis adapter to run Action Cable in production # gem 'redis', '~> 3.0' # Use ActiveModel has_secure_password # gem 'bcrypt', '~> 3.1.7' # Use Capistrano for deployment # gem 'capistrano-rails', group: :development gem 'bindex', '0.8.1' group :development, :test do # Call 'byebug' anywhere in the code to stop execution and get a debugger console gem 'byebug', platform: :mri end

Gemfile.lock

GEM remote: https://rubygems.org/ specs: actioncable (5.0.0.1) actionpack (= 5.0.0.1) nio4r (~> 1.2) websocket-driver (~> 0.6.1) actionmailer (5.0.0.1) actionpack (= 5.0.0.1) actionview (= 5.0.0.1) activejob (= 5.0.0.1) mail (~> 2.5, >= 2.5.4) rails-dom-testing (~> 2.0) actionpack (5.0.0.1) actionview (= 5.0.0.1) activesupport (= 5.0.0.1) rack (~> 2.0) rack-test (~> 0.6.3) rails-dom-testing (~> 2.0) rails-html-sanitizer (~> 1.0, >= 1.0.2) actionview (5.0.0.1) activesupport (= 5.0.0.1) builder (~> 3.1) erubis (~> 2.7.0) rails-dom-testing (~> 2.0) rails-html-sanitizer (~> 1.0, >= 1.0.2) activejob (5.0.0.1) activesupport (= 5.0.0.1)

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

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

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

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

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

guest

回答1

0

ベストアンサー

環境を再構築して実行

投稿2020/01/24 00:16

退会済みユーザー

退会済みユーザー

総合スコア0

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

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

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

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

ただいまの回答率
85.48%

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

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

質問する

関連した質問