diff --git a/Dockerfile b/Dockerfile index e6e3473..aa89d24 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM ruby:3.0.0 +FROM ruby:3.1.6 RUN apt-get update && \ apt-get install -y \ diff --git a/Dockerfile.dev b/Dockerfile.dev new file mode 100644 index 0000000..57f07ea --- /dev/null +++ b/Dockerfile.dev @@ -0,0 +1,26 @@ +FROM ruby:3.1.6 + +RUN apt-get update && \ + apt-get install -y build-essential libpq-dev default-mysql-client nodejs && \ + rm -rf /var/lib/apt/lists/* + +RUN gem install bundler +WORKDIR /app + +# Gemfileをコピーしてbundle install +COPY Gemfile Gemfile.lock* ./ +RUN bundle config set --local jobs 4 && \ + bundle config set --local retry 3 && \ + bundle config set --local without '' && \ + bundle install + +# アプリケーションファイルをコピー +COPY . . + +# エントリーポイントスクリプトをコピー +COPY dev-entrypoint.sh /usr/local/bin/ +RUN chmod +x /usr/local/bin/dev-entrypoint.sh + +ENTRYPOINT ["dev-entrypoint.sh"] +CMD ["bundle", "exec", "rails", "server", "-b", "0.0.0.0", "-p", "3000"] +EXPOSE 3000 diff --git a/Gemfile b/Gemfile index 67496a8..6ae7e69 100644 --- a/Gemfile +++ b/Gemfile @@ -1,7 +1,7 @@ # frozen_string_literal: true source 'https://rubygems.org' -ruby '3.0.0' +ruby '3.1.6' git_source(:github) do |repo_name| repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?('/') @@ -17,13 +17,13 @@ gem 'mini_racer', platforms: :ruby gem 'mysql2' gem 'psych', '~> 4.0' gem 'puma' -gem 'rails', '7.0.0' +gem 'rails', '~> 7.1.0' gem 'ransack' gem 'sass-rails' gem 'slim-rails' gem 'webpacker' -group :development, :test, optional: true do +group :development, :test do gem 'awesome_print' gem 'bullet' gem 'byebug', platform: :mri @@ -39,7 +39,7 @@ group :development, :test, optional: true do gem 'simplecov' end -group :development, optional: true do +group :development do gem 'annotate' gem 'better_errors' gem 'brakeman', require: false diff --git a/Gemfile.lock b/Gemfile.lock index 800ced6..ed0209d 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -1,110 +1,136 @@ GEM remote: https://rubygems.org/ specs: - actioncable (7.0.0) - actionpack (= 7.0.0) - activesupport (= 7.0.0) + actioncable (7.1.5.1) + actionpack (= 7.1.5.1) + activesupport (= 7.1.5.1) nio4r (~> 2.0) websocket-driver (>= 0.6.1) - actionmailbox (7.0.0) - actionpack (= 7.0.0) - activejob (= 7.0.0) - activerecord (= 7.0.0) - activestorage (= 7.0.0) - activesupport (= 7.0.0) + zeitwerk (~> 2.6) + actionmailbox (7.1.5.1) + actionpack (= 7.1.5.1) + activejob (= 7.1.5.1) + activerecord (= 7.1.5.1) + activestorage (= 7.1.5.1) + activesupport (= 7.1.5.1) mail (>= 2.7.1) - actionmailer (7.0.0) - actionpack (= 7.0.0) - actionview (= 7.0.0) - activejob (= 7.0.0) - activesupport (= 7.0.0) + net-imap + net-pop + net-smtp + actionmailer (7.1.5.1) + actionpack (= 7.1.5.1) + actionview (= 7.1.5.1) + activejob (= 7.1.5.1) + activesupport (= 7.1.5.1) mail (~> 2.5, >= 2.5.4) - rails-dom-testing (~> 2.0) - actionpack (7.0.0) - actionview (= 7.0.0) - activesupport (= 7.0.0) - rack (~> 2.0, >= 2.2.0) + net-imap + net-pop + net-smtp + rails-dom-testing (~> 2.2) + actionpack (7.1.5.1) + actionview (= 7.1.5.1) + activesupport (= 7.1.5.1) + nokogiri (>= 1.8.5) + racc + rack (>= 2.2.4) + rack-session (>= 1.0.1) rack-test (>= 0.6.3) - rails-dom-testing (~> 2.0) - rails-html-sanitizer (~> 1.0, >= 1.2.0) - actiontext (7.0.0) - actionpack (= 7.0.0) - activerecord (= 7.0.0) - activestorage (= 7.0.0) - activesupport (= 7.0.0) + rails-dom-testing (~> 2.2) + rails-html-sanitizer (~> 1.6) + actiontext (7.1.5.1) + actionpack (= 7.1.5.1) + activerecord (= 7.1.5.1) + activestorage (= 7.1.5.1) + activesupport (= 7.1.5.1) globalid (>= 0.6.0) nokogiri (>= 1.8.5) - actionview (7.0.0) - activesupport (= 7.0.0) + actionview (7.1.5.1) + activesupport (= 7.1.5.1) builder (~> 3.1) - erubi (~> 1.4) - rails-dom-testing (~> 2.0) - rails-html-sanitizer (~> 1.1, >= 1.2.0) - activejob (7.0.0) - activesupport (= 7.0.0) + erubi (~> 1.11) + rails-dom-testing (~> 2.2) + rails-html-sanitizer (~> 1.6) + activejob (7.1.5.1) + activesupport (= 7.1.5.1) globalid (>= 0.3.6) - activemodel (7.0.0) - activesupport (= 7.0.0) - activerecord (7.0.0) - activemodel (= 7.0.0) - activesupport (= 7.0.0) - activestorage (7.0.0) - actionpack (= 7.0.0) - activejob (= 7.0.0) - activerecord (= 7.0.0) - activesupport (= 7.0.0) + activemodel (7.1.5.1) + activesupport (= 7.1.5.1) + activerecord (7.1.5.1) + activemodel (= 7.1.5.1) + activesupport (= 7.1.5.1) + timeout (>= 0.4.0) + activestorage (7.1.5.1) + actionpack (= 7.1.5.1) + activejob (= 7.1.5.1) + activerecord (= 7.1.5.1) + activesupport (= 7.1.5.1) marcel (~> 1.0) - mini_mime (>= 1.1.0) - activesupport (7.0.0) + activesupport (7.1.5.1) + base64 + benchmark (>= 0.3) + bigdecimal concurrent-ruby (~> 1.0, >= 1.0.2) + connection_pool (>= 2.2.5) + drb i18n (>= 1.6, < 2) + logger (>= 1.4.2) minitest (>= 5.1) + mutex_m + securerandom (>= 0.3) tzinfo (~> 2.0) annotate (3.2.0) activerecord (>= 3.2, < 8.0) rake (>= 10.4, < 14.0) - ast (2.4.2) + ast (2.4.3) awesome_print (1.9.2) + base64 (0.3.0) bcrypt (3.1.20) + benchmark (0.4.1) better_errors (2.10.1) erubi (>= 1.0.0) rack (>= 0.9.0) rouge (>= 1.0.0) + bigdecimal (3.2.2) bindex (0.8.1) binding_of_caller (1.0.1) debug_inspector (>= 1.2.0) - brakeman (6.1.2) + brakeman (7.0.2) racc builder (3.3.0) - bullet (7.2.0) + bullet (8.0.8) activesupport (>= 3.0.0) uniform_notifier (~> 1.11) - bulma-rails (1.0.2) + bulma-rails (1.0.4) dartsass-rails (~> 0.5.0) - byebug (11.1.3) + byebug (12.0.0) + cgi (0.5.0) code_analyzer (0.5.5) sexp_processor coderay (1.1.3) - concurrent-ruby (1.3.3) + concurrent-ruby (1.3.5) + connection_pool (2.5.3) crass (1.0.6) dartsass-rails (0.5.1) railties (>= 6.0.0) sass-embedded (~> 1.63) - date (3.3.4) - debase (0.2.4.1) - debase-ruby_core_source (>= 0.10.2) - debase-ruby_core_source (3.3.1) + date (3.4.1) + debase (0.2.9) + debase-ruby_core_source (>= 3.4.1) + debase-ruby_core_source (3.4.1) debug_inspector (1.2.0) - diff-lcs (1.5.1) + diff-lcs (1.6.2) docile (1.4.1) - erubi (1.13.0) + drb (2.2.3) + erb (4.0.4) + cgi (>= 0.3.3) + erubi (1.13.1) erubis (2.7.0) - factory_bot (6.4.6) - activesupport (>= 5.0.0) - factory_bot_rails (6.4.3) - factory_bot (~> 6.4) - railties (>= 5.0.0) - ffi (1.17.0) + factory_bot (6.5.4) + activesupport (>= 6.1.0) + factory_bot_rails (6.5.0) + factory_bot (~> 6.5) + railties (>= 6.1.0) + ffi (1.17.2-x86_64-linux-gnu) globalid (1.2.1) activesupport (>= 6.1) gon (6.4.0) @@ -112,14 +138,21 @@ GEM i18n (>= 0.7) multi_json request_store (>= 1.0) - google-protobuf (3.25.5-x86_64-linux) - i18n (1.14.5) + google-protobuf (4.31.1-x86_64-linux-gnu) + bigdecimal + rake (>= 13) + i18n (1.14.7) concurrent-ruby (~> 1.0) + io-console (0.8.0) + irb (1.15.2) + pp (>= 0.6.0) + rdoc (>= 4.0.0) + reline (>= 0.4.2) jquery-rails (4.6.0) rails-dom-testing (>= 1, < 3) railties (>= 4.2.0) thor (>= 0.14, < 2.0) - json (2.7.2) + json (2.12.2) kaminari (1.2.2) activesupport (>= 4.1.0) kaminari-actionview (= 1.2.2) @@ -132,12 +165,14 @@ GEM activerecord kaminari-core (= 1.2.2) kaminari-core (1.2.2) - language_server-protocol (3.17.0.3) - libv8-node (21.7.2.0-x86_64-linux) + language_server-protocol (3.17.0.5) + libv8-node (24.1.0.0-x86_64-linux) + lint_roller (1.1.0) listen (3.9.0) rb-fsevent (~> 0.10, >= 0.10.3) rb-inotify (~> 0.9, >= 0.9.10) - loofah (2.22.0) + logger (1.7.0) + loofah (2.24.1) crass (~> 1.0.2) nokogiri (>= 1.12.0) mail (2.8.1) @@ -148,34 +183,39 @@ GEM marcel (1.0.4) method_source (1.1.0) mini_mime (1.1.5) - mini_racer (0.12.0) - libv8-node (~> 21.7.2.0) - minitest (5.24.1) + mini_racer (0.19.0) + libv8-node (~> 24.1.0.0) + minitest (5.25.5) multi_json (1.15.0) + mutex_m (0.3.0) mysql2 (0.5.6) - net-imap (0.4.17) + net-imap (0.5.9) date net-protocol net-pop (0.1.2) net-protocol net-protocol (0.2.2) timeout - net-smtp (0.5.0) + net-smtp (0.5.1) net-protocol - nio4r (2.7.3) - nokogiri (1.16.7-x86_64-linux) + nio4r (2.7.4) + nokogiri (1.18.8-x86_64-linux-gnu) racc (~> 1.4) - parallel (1.25.1) - parser (3.3.4.2) + parallel (1.27.0) + parser (3.3.8.0) ast (~> 2.4.1) racc - pry (0.14.2) + pp (0.6.2) + prettyprint + prettyprint (0.2.0) + prism (1.4.0) + pry (0.15.2) coderay (~> 1.1) method_source (~> 1.0) - pry-byebug (3.10.1) - byebug (~> 11.0) - pry (>= 0.13, < 0.15) - pry-doc (1.5.0) + pry-byebug (3.11.0) + byebug (~> 12.0) + pry (>= 0.13, < 0.16) + pry-doc (1.6.0) pry (~> 0.11) yard (~> 0.9.11) pry-rails (0.3.11) @@ -185,37 +225,42 @@ GEM pry (~> 0.13) psych (4.0.6) stringio - puma (6.4.2) + puma (6.6.0) nio4r (~> 2.0) racc (1.8.1) - rack (2.2.10) - rack-mini-profiler (3.3.1) + rack (3.1.16) + rack-mini-profiler (4.0.0) rack (>= 1.2.0) rack-proxy (0.7.7) rack - rack-test (2.1.0) + rack-session (2.1.1) + base64 (>= 0.1.0) + rack (>= 3.0.0) + rack-test (2.2.0) rack (>= 1.3) - rails (7.0.0) - actioncable (= 7.0.0) - actionmailbox (= 7.0.0) - actionmailer (= 7.0.0) - actionpack (= 7.0.0) - actiontext (= 7.0.0) - actionview (= 7.0.0) - activejob (= 7.0.0) - activemodel (= 7.0.0) - activerecord (= 7.0.0) - activestorage (= 7.0.0) - activesupport (= 7.0.0) + rackup (2.2.1) + rack (>= 3) + rails (7.1.5.1) + actioncable (= 7.1.5.1) + actionmailbox (= 7.1.5.1) + actionmailer (= 7.1.5.1) + actionpack (= 7.1.5.1) + actiontext (= 7.1.5.1) + actionview (= 7.1.5.1) + activejob (= 7.1.5.1) + activemodel (= 7.1.5.1) + activerecord (= 7.1.5.1) + activestorage (= 7.1.5.1) + activesupport (= 7.1.5.1) bundler (>= 1.15.0) - railties (= 7.0.0) - rails-dom-testing (2.2.0) + railties (= 7.1.5.1) + rails-dom-testing (2.3.0) activesupport (>= 5.0.0) minitest nokogiri (>= 1.6) - rails-html-sanitizer (1.6.0) + rails-html-sanitizer (1.6.2) loofah (~> 2.21) - nokogiri (~> 1.14) + nokogiri (>= 1.15.7, != 1.16.7, != 1.16.6, != 1.16.5, != 1.16.4, != 1.16.3, != 1.16.2, != 1.16.1, != 1.16.0.rc1, != 1.16.0) rails_best_practices (1.23.2) activesupport code_analyzer (~> 0.5.5) @@ -224,70 +269,76 @@ GEM json require_all (~> 3.0) ruby-progressbar - railties (7.0.0) - actionpack (= 7.0.0) - activesupport (= 7.0.0) - method_source + railties (7.1.5.1) + actionpack (= 7.1.5.1) + activesupport (= 7.1.5.1) + irb + rackup (>= 1.0.0) rake (>= 12.2) - thor (~> 1.0) - zeitwerk (~> 2.5) + thor (~> 1.0, >= 1.2.2) + zeitwerk (~> 2.6) rainbow (3.1.1) - rake (13.2.1) - ransack (4.2.0) + rake (13.3.0) + ransack (4.3.0) activerecord (>= 6.1.5) activesupport (>= 6.1.5) i18n rb-fsevent (0.11.2) rb-inotify (0.11.1) ffi (~> 1.0) - regexp_parser (2.9.2) + rdoc (6.14.1) + erb + psych (>= 4.0.0) + regexp_parser (2.10.0) + reline (0.6.1) + io-console (~> 0.5) request_store (1.7.0) rack (>= 1.4) require_all (3.0.0) - rexml (3.3.4) - strscan - rouge (4.3.0) - rspec-core (3.13.0) + rouge (4.5.2) + rspec-core (3.13.5) rspec-support (~> 3.13.0) - rspec-expectations (3.13.1) + rspec-expectations (3.13.5) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.13.0) - rspec-mocks (3.13.1) + rspec-mocks (3.13.5) diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.13.0) - rspec-rails (6.1.3) - actionpack (>= 6.1) - activesupport (>= 6.1) - railties (>= 6.1) + rspec-rails (7.1.1) + actionpack (>= 7.0) + activesupport (>= 7.0) + railties (>= 7.0) rspec-core (~> 3.13) rspec-expectations (~> 3.13) rspec-mocks (~> 3.13) rspec-support (~> 3.13) - rspec-support (3.13.1) - rubocop (1.65.1) + rspec-support (3.13.4) + rubocop (1.77.0) json (~> 2.3) - language_server-protocol (>= 3.17.0) + language_server-protocol (~> 3.17.0.2) + lint_roller (~> 1.1.0) parallel (~> 1.10) parser (>= 3.3.0.2) rainbow (>= 2.2.2, < 4.0) - regexp_parser (>= 2.4, < 3.0) - rexml (>= 3.2.5, < 4.0) - rubocop-ast (>= 1.31.1, < 2.0) + regexp_parser (>= 2.9.3, < 3.0) + rubocop-ast (>= 1.45.1, < 2.0) ruby-progressbar (~> 1.7) - unicode-display_width (>= 2.4.0, < 3.0) - rubocop-ast (1.32.0) - parser (>= 3.3.1.0) - rubocop-rails (2.25.1) + unicode-display_width (>= 2.4.0, < 4.0) + rubocop-ast (1.45.1) + parser (>= 3.3.7.2) + prism (~> 1.4) + rubocop-rails (2.32.0) activesupport (>= 4.2.0) + lint_roller (~> 1.1) rack (>= 1.1) - rubocop (>= 1.33.0, < 2.0) - rubocop-ast (>= 1.31.1, < 2.0) - ruby-debug-ide (0.7.3) + rubocop (>= 1.75.0, < 2.0) + rubocop-ast (>= 1.44.0, < 2.0) + ruby-debug-ide (0.7.5) rake (>= 0.8.1) ruby-progressbar (1.13.0) - sass-embedded (1.69.5) - google-protobuf (~> 3.23) - rake (>= 13.0.0) + sass-embedded (1.89.2) + google-protobuf (~> 4.31) + rake (>= 13) sass-rails (6.0.0) sassc-rails (~> 2.1, >= 2.1.1) sassc (2.4.0) @@ -298,42 +349,45 @@ GEM sprockets (> 3.0) sprockets-rails tilt - semantic_range (3.0.0) - sexp_processor (4.17.2) + securerandom (0.4.1) + semantic_range (3.1.0) + sexp_processor (4.17.3) simplecov (0.22.0) docile (~> 1.1) simplecov-html (~> 0.11) simplecov_json_formatter (~> 0.1) - simplecov-html (0.12.3) + simplecov-html (0.13.1) simplecov_json_formatter (0.1.4) slim (5.2.1) temple (~> 0.10.0) tilt (>= 2.1.0) - slim-rails (3.6.3) + slim-rails (3.7.0) actionpack (>= 3.1) railties (>= 3.1) slim (>= 3.0, < 6.0, != 5.0.0) - spring (4.2.1) + spring (4.3.0) spring-watcher-listen (2.1.0) listen (>= 2.7, < 4.0) spring (>= 4) - sprockets (4.2.1) + sprockets (4.2.2) concurrent-ruby (~> 1.0) + logger rack (>= 2.2.4, < 4) sprockets-rails (3.5.2) actionpack (>= 6.1) activesupport (>= 6.1) sprockets (>= 3.0.0) - stringio (3.1.1) - strscan (3.1.0) + stringio (3.1.7) temple (0.10.3) - thor (1.3.1) - tilt (2.4.0) - timeout (0.4.1) + thor (1.3.2) + tilt (2.6.0) + timeout (0.4.3) tzinfo (2.0.6) concurrent-ruby (~> 1.0) - unicode-display_width (2.5.0) - uniform_notifier (1.16.0) + unicode-display_width (3.1.4) + unicode-emoji (~> 4.0, >= 4.0.4) + unicode-emoji (4.0.4) + uniform_notifier (1.17.0) web-console (4.2.1) actionview (>= 6.0.0) activemodel (>= 6.0.0) @@ -344,14 +398,15 @@ GEM rack-proxy (>= 0.6.1) railties (>= 5.2) semantic_range (>= 2.3.0) - websocket-driver (0.7.6) + websocket-driver (0.8.0) + base64 websocket-extensions (>= 0.1.0) websocket-extensions (0.1.5) - yard (0.9.36) - zeitwerk (2.6.17) + yard (0.9.37) + zeitwerk (2.6.18) PLATFORMS - x86_64-linux + x86_64-linux-gnu DEPENDENCIES annotate @@ -377,7 +432,7 @@ DEPENDENCIES psych (~> 4.0) puma rack-mini-profiler - rails (= 7.0.0) + rails (~> 7.1.0) rails_best_practices ransack rspec-rails @@ -393,7 +448,7 @@ DEPENDENCIES webpacker RUBY VERSION - ruby 3.0.0p0 + ruby 3.1.6p260 BUNDLED WITH - 2.5.17 + 2.6.9 diff --git a/app/assets/stylesheets/application.scss b/app/assets/stylesheets/application.scss index aa9a37d..c4beee5 100644 --- a/app/assets/stylesheets/application.scss +++ b/app/assets/stylesheets/application.scss @@ -5,4 +5,4 @@ @import 'reset'; @import 'component'; -@import 'bulma'; +/* @import 'bulma'; */ /* 開発環境では一時的にコメントアウト */ diff --git a/config/environments/development.rb b/config/environments/development.rb index 092daa3..a1222f7 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -64,7 +64,7 @@ end # for development.log - config.web_console.whitelisted_ips = '0.0.0.0/0' + # config.web_console.whitelisted_ips = '0.0.0.0/0' # 一時的にコメントアウト # Raises error for missing translations # config.action_view.raise_on_missing_translations = true @@ -74,11 +74,11 @@ # config.file_watcher = ActiveSupport::EventedFileUpdateChecker config.file_watcher = ActiveSupport::FileUpdateChecker config.serve_static_assets = true - config.after_initialize do - Bullet.enable = true - Bullet.alert = true - Bullet.bullet_logger = true - Bullet.console = true - Bullet.rails_logger = true - end + # config.after_initialize do + # Bullet.enable = true + # Bullet.alert = true + # Bullet.bullet_logger = true + # Bullet.console = true + # Bullet.rails_logger = true + # end end diff --git a/config/initializers/rack_mini_profiler.rb b/config/initializers/rack_mini_profiler.rb index fdb538a..93f81ad 100644 --- a/config/initializers/rack_mini_profiler.rb +++ b/config/initializers/rack_mini_profiler.rb @@ -1,7 +1,8 @@ # frozen_string_literal: true -if Rails.env.development? - require 'rack-mini-profiler' - # initialization is skipped so trigger it - Rack::MiniProfilerRails.initialize!(Rails.application) -end +# 一時的にコメントアウト(開発環境セットアップ中) +# if Rails.env.development? +# require 'rack-mini-profiler' +# # initialization is skipped so trigger it +# Rack::MiniProfilerRails.initialize!(Rails.application) +# end diff --git a/config/puma.rb b/config/puma.rb index 2582ec7..75fcf60 100644 --- a/config/puma.rb +++ b/config/puma.rb @@ -49,5 +49,8 @@ # Allow puma to be restarted by `rails restart` command. plugin :tmp_restart -app_root = File.expand_path('..', __dir__) -bind "unix://#{app_root}/tmp/sockets/puma.sock" +# 開発環境以外でのみUnixソケットを使用(環境変数でチェック) +unless ENV.fetch('RAILS_ENV', 'development') == 'development' + app_root = File.expand_path('..', __dir__) + bind "unix://#{app_root}/tmp/sockets/puma.sock" +end diff --git a/dev-entrypoint.sh b/dev-entrypoint.sh new file mode 100755 index 0000000..e51dd1c --- /dev/null +++ b/dev-entrypoint.sh @@ -0,0 +1,12 @@ +#!/bin/bash +set -e + +# SECRET_KEY_BASEが設定されていない場合は生成 +if [ -z "$SECRET_KEY_BASE" ]; then + echo "Generating SECRET_KEY_BASE for development..." + export SECRET_KEY_BASE=$(bundle exec rails secret) + echo "SECRET_KEY_BASE generated successfully" +fi + +# 引数で渡されたコマンドを実行 +exec "$@" diff --git a/docker-compose.dev.yml b/docker-compose.dev.yml index bffe0c8..9c43bb3 100644 --- a/docker-compose.dev.yml +++ b/docker-compose.dev.yml @@ -2,11 +2,14 @@ version: '3' services: app: build: - args: - RAILS_ENV: development + dockerfile: Dockerfile.dev + ports: + - "3000:3000" volumes: - .:/app environment: - TZ=${TZ} - RAILS_ENV=development - - BUCKY_DB_NAME=bucky_development \ No newline at end of file + - BUCKY_DB_NAME=bucky_development + depends_on: + - db \ No newline at end of file diff --git a/docker-compose.with_mysql.yml b/docker-compose.with_mysql.yml index b8a364a..a0165fa 100644 --- a/docker-compose.with_mysql.yml +++ b/docker-compose.with_mysql.yml @@ -5,7 +5,7 @@ services: image: mysql:5.7.39 container_name: bm-mysql volumes: - - ./docker/mysql/volumes:/var/lib/mysql + - mysql_data:/var/lib/mysql environment: - TZ=${TZ} - MYSQL_ROOT_PASSWORD=password @@ -18,4 +18,6 @@ services: - BUCKY_DB_PASSWORD=${BUCKY_DB_PASSWORD:-password} - BUCKY_DB_HOSTNAME=${BUCKY_DB_HOSTNAME:-db} depends_on: - - db \ No newline at end of file + - db +volumes: + mysql_data: \ No newline at end of file