質問編集履歴

3

情報の追加

2021/05/11 07:00

投稿

divclass123
divclass123

スコア35

test CHANGED
File without changes
test CHANGED
@@ -619,3 +619,15 @@
619
619
 
620
620
 
621
621
  そもそも、本番環境のデータベース はRDSなので、自分のアプローチが何か間違ってるかもしれません。。。
622
+
623
+
624
+
625
+ # 環境
626
+
627
+
628
+
629
+ 各環境は
630
+
631
+ **[このアプリのGithub](https://github.com/Harasou21/coffee_passport)**
632
+
633
+ お手数ですが、こちらのreadMeをご確認お願い申し上げます。

2

情報の追加

2021/05/11 07:00

投稿

divclass123
divclass123

スコア35

test CHANGED
@@ -1 +1 @@
1
- rake exit status: 1 (SSHKit::Command::Failed)
1
+ LoadError: libmysqlclient.so.18:
test CHANGED
@@ -18,470 +18,514 @@
18
18
 
19
19
 
20
20
 
21
+
22
+
23
+
24
+
25
+ を実行したら以下のようなエラーに
26
+
27
+ なりました。
28
+
29
+
30
+
21
31
  RDSのMySQLは8系でdocker開発環境は5.7なのでそこら辺も関係あるかもしれません。
22
32
 
23
33
 
24
34
 
35
+ [追記]
36
+
37
+
38
+
39
+
40
+
41
+ ```
42
+
43
+ db:
44
+
45
+ image: mysql:8.0.21
46
+
47
+ environment:
48
+
49
+ MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
50
+
51
+ MYSQL_HOST: db
52
+
53
+ ports:
54
+
55
+ - '3306:3306'
56
+
57
+ volumes:
58
+
59
+ - ./tmp/db:/var/lib/mysql
60
+
61
+ command: --default-authentication-plugin=mysql_native_password
62
+
63
+ ```
64
+
65
+
66
+
67
+ こんな感じでdocker-compose.ymlを編集して、buildし直したら上手く立ち上がって、その後、再度bundle exec cap production deployを実行しましたが、エラー内容変わりませんでした。
68
+
69
+
70
+
71
+
72
+
73
+
74
+
75
+ # エラー内容
76
+
77
+
78
+
79
+ ```
80
+
81
+
82
+
83
+ /Users/soichirohara/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/sshkit-1.21.2/lib/sshkit/command.rb:97:in `exit_status=': rake exit status: 1 (SSHKit::Command::Failed)
84
+
85
+ rake stdout: Nothing written
86
+
87
+ rake stderr: rake aborted!
88
+
89
+ LoadError: libmysqlclient.so.18: cannot open shared object file: No such file or directory - /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/mysql2-0.5.3/lib/mysql2/mysql2.so
90
+
91
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
92
+
93
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
94
+
95
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
96
+
97
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
98
+
99
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
100
+
101
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/activesupport-6.1.3.1/lib/active_support/dependencies.rb:332:in `block in require'
102
+
103
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/activesupport-6.1.3.1/lib/active_support/dependencies.rb:299:in `load_dependency'
104
+
105
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/activesupport-6.1.3.1/lib/active_support/dependencies.rb:332:in `require'
106
+
107
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/mysql2-0.5.3/lib/mysql2.rb:36:in `<main>'
108
+
109
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
110
+
111
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
112
+
113
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
114
+
115
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
116
+
117
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
118
+
119
+ /var/www/coffee_passport/releases/20210511045750/config/application.rb:7:in `<top (required)>'
120
+
121
+ /var/www/coffee_passport/releases/20210511045750/Rakefile:4:in `require_relative'
122
+
123
+ /var/www/coffee_passport/releases/20210511045750/Rakefile:4:in `<top (required)>'
124
+
125
+ /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/rake-13.0.3/exe/rake:27:in `<top (required)>'
126
+
127
+ /home/ec2-user/.rbenv/versions/2.6.5/bin/bundle:23:in `load'
128
+
129
+ /home/ec2-user/.rbenv/versions/2.6.5/bin/bundle:23:in `<main>'
130
+
131
+ ```
132
+
133
+
134
+
135
+ capistrano.log
136
+
137
+
138
+
139
+ のエラーログもこんな感じだったので、teratailは1000字以内で入力しなければならないので、必要であれば共有したいと思います。
140
+
141
+
142
+
143
+ # 該当のソースコード
144
+
145
+
146
+
147
+ **[このアプリのGithub](https://github.com/Harasou21/coffee_passport)**
148
+
149
+
150
+
151
+ **database.yml**
152
+
153
+
154
+
155
+ ```
156
+
157
+ default: &default
158
+
159
+ adapter: mysql2
160
+
161
+ encoding: utf8
162
+
163
+ pool: <%= ENV.fetch("RAILS_MAX_THREADS") { 5 } %>
164
+
165
+ username: root
166
+
167
+ password: <%= ENV['MYSQL_ROOT_PASSWORD'] %>
168
+
169
+ socket: /tmp/mysql.sock
170
+
171
+ host: <%= ENV['MYSQL_HOST'] || 'localhost' %>
172
+
173
+
174
+
175
+ development:
176
+
177
+ <<: *default
178
+
179
+ database: coffee_passport_development
180
+
181
+
182
+
183
+
184
+
185
+
186
+
187
+ # Warning: The database defined as "test" will be erased and
188
+
189
+ # re-generated from your development database when you run "rake".
190
+
191
+ # Do not set this db to the same as development or production.
192
+
193
+ test:
194
+
195
+ <<: *default
196
+
197
+ database: coffee_passport_test
198
+
199
+
200
+
201
+
202
+
203
+ # As with config/credentials.yml, you never want to store sensitive information,
204
+
205
+ # like your database password, in your source code. If your source code is
206
+
207
+ # ever seen by anyone, they now have access to your database.
208
+
209
+ #
210
+
211
+ # Instead, provide the password as a unix environment variable when you boot
212
+
213
+ # the app. Read https://guides.rubyonrails.org/configuring.html#configuring-a-database
214
+
215
+ # for a full rundown on how to provide these environment variables in a
216
+
217
+ # production deployment.
218
+
219
+ #
220
+
221
+ # On Heroku and other platform providers, you may have a full connection URL
222
+
223
+ # available as an environment variable. For example:
224
+
225
+ #
226
+
227
+ # DATABASE_URL="mysql2://myuser:mypass@localhost/somedatabase"
228
+
229
+ #
230
+
231
+ # You can use this database configuration with:
232
+
233
+ #
234
+
235
+ # production:
236
+
237
+ # url: <%= ENV['DATABASE_URL'] %>
238
+
239
+ #
240
+
241
+ production:
242
+
243
+ <<: *default
244
+
245
+ database: coffee_passport_production
246
+
247
+ username: root
248
+
249
+ password: <%= ENV['MYSQL_ROOT_PASSWORD'] %>
250
+
251
+ host: cp-mysql.c3sv1rwobfad.ap-northeast-1.rds.amazonaws.com
252
+
253
+
254
+
255
+ ```
256
+
257
+
258
+
259
+ **Gemfile**
260
+
261
+
262
+
263
+ ```
264
+
265
+ source 'https://rubygems.org'
266
+
267
+ git_source(:github) { |repo| "https://github.com/#{repo}.git" }
268
+
269
+
270
+
271
+ ruby '2.6.5'
272
+
273
+
274
+
275
+ # Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
276
+
277
+ gem 'rails', '6.1.3.1'
278
+
279
+ # Use mysql as the database for Active Record
280
+
281
+ gem 'mysql2', '>= 0.4.4'
282
+
283
+ # Use Puma as the app server
284
+
285
+ gem 'puma', '~> 3.11'
286
+
287
+ # Use SCSS for stylesheets
288
+
289
+ gem 'sass-rails', '~> 5'
290
+
291
+ # Transpile app-like JavaScript. Read more: https://github.com/rails/webpacker
292
+
293
+ gem 'webpacker', '~> 4.0'
294
+
295
+ # Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
296
+
297
+ gem 'turbolinks', '~> 5'
298
+
299
+ # Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
300
+
301
+ gem 'jbuilder', '~> 2.7'
302
+
303
+ # Use Redis adapter to run Action Cable in production
304
+
305
+ # gem 'redis', '~> 4.0'
306
+
307
+ # Use Active Model has_secure_password
308
+
309
+ gem 'bcrypt', '~> 3.1.7'
310
+
311
+
312
+
313
+
314
+
315
+ # Use Active Storage variant
316
+
317
+ # gem 'image_processing', '~> 1.2'
318
+
319
+
320
+
321
+ # Reduces boot times through caching; required in config/boot.rb
322
+
323
+ gem 'bootsnap', '>= 1.4.2', require: false
324
+
325
+
326
+
327
+ group :development, :test do
328
+
329
+ # Call 'byebug' anywhere in the code to stop execution and get a debugger console
330
+
331
+ gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
332
+
333
+ gem 'rspec-rails'
334
+
335
+ gem 'factory_bot_rails'
336
+
337
+ gem 'faker'
338
+
339
+ gem 'capistrano'
340
+
341
+ gem 'capistrano-rbenv'
342
+
343
+ gem 'capistrano-bundler'
344
+
345
+ gem 'capistrano-rails'
346
+
347
+ gem 'capistrano3-unicorn'
348
+
349
+ end
350
+
351
+
352
+
353
+ group :development do
354
+
355
+ # Access an interactive console on exception pages or by calling 'console' anywhere in the code.
356
+
357
+ gem 'web-console', '>= 3.3.0'
358
+
359
+ gem 'listen', '>= 3.0.5', '< 3.2'
360
+
361
+ # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
362
+
363
+ gem 'spring'
364
+
365
+ gem 'spring-watcher-listen', '~> 2.0.0'
366
+
367
+ gem 'rubocop', require: false
368
+
369
+ end
370
+
371
+
372
+
373
+ group :test do
374
+
375
+ # Adds support for Capybara system testing and selenium driver
376
+
377
+ gem 'capybara', '>= 2.15'
378
+
379
+ gem 'selenium-webdriver'
380
+
381
+ # Easy installation and use of web drivers to run system tests with browsers
382
+
383
+ gem 'webdrivers'
384
+
385
+ gem 'launchy'
386
+
387
+ end
388
+
389
+
390
+
391
+ group :production do
392
+
393
+ gem 'unicorn', '5.4.1'
394
+
395
+ end
396
+
397
+
398
+
399
+ # Windows does not include zoneinfo files, so bundle the tzinfo-data gem
400
+
401
+ gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
402
+
403
+
404
+
405
+ gem 'pry-rails'
406
+
407
+
408
+
409
+ gem "mimemagic"
410
+
411
+ gem 'image_processing', '~> 1.2'
412
+
413
+ gem 'active_hash'
414
+
415
+ gem 'payjp'
416
+
417
+ gem 'ransack'
418
+
419
+ gem 'will_paginate', '3.1.8'
420
+
421
+ gem 'bootstrap-will_paginate', '1.0.0'
422
+
423
+ gem "jquery-rails"
424
+
425
+ gem 'omniauth-twitter'
426
+
427
+ gem 'omniauth-facebook'
428
+
429
+ gem 'omniauth-google-oauth2'
430
+
431
+ gem 'omniauth-rails_csrf_protection'
432
+
433
+ gem 'oauth2'
434
+
435
+ gem "aws-sdk-s3", require: false
436
+
437
+ gem 'faker'
438
+
439
+ gem 'dotenv-rails'
440
+
441
+ # rack のアップデートのバグで画像が上手く開いてくれない見たいなので、グレードダウン(近々修正くるらしい)
442
+
443
+ gem 'rails-i18n'
444
+
445
+ ```
446
+
447
+
448
+
449
+
450
+
451
+
452
+
453
+ # 試したこと
454
+
455
+
456
+
457
+ 私の行った手順は以下です。
458
+
459
+ (1)
460
+
461
+
462
+
463
+ ```
464
+
465
+ sudo yum install libmysqlclient.so.18
466
+
467
+ ```
468
+
469
+
470
+
471
+ を実行したら 
472
+
473
+
474
+
475
+ ```
476
+
477
+ sudo: yum: command not found
478
+
479
+ ```
480
+
481
+
482
+
483
+ とエラーが出たので
484
+
485
+
486
+
487
+ ```
488
+
489
+ brew install yum
490
+
491
+ ```
492
+
493
+
494
+
495
+ を実行。
496
+
497
+
498
+
499
+ ```
500
+
501
+ ==> Searching for similarly named formulae...
502
+
503
+ Error: No similarly named formulae found.
504
+
505
+ Error: No available formula or cask with the name "yum".
506
+
507
+ ==> Searching for a previously deleted formula (in the last month)...
508
+
509
+ Error: No previously deleted formula found.
510
+
511
+ ==> Searching taps on GitHub...
512
+
513
+ Error: No formulae found in taps.
514
+
515
+
516
+
517
+ ```
518
+
519
+
520
+
521
+ ```
522
+
523
+ docker-compose exec web apt-get install libmysqlclient.so.18
524
+
525
+ ```
526
+
25
527
  を実行したら
26
528
 
27
-
28
-
29
-
30
-
31
- # エラー内容
32
-
33
-
34
-
35
- ```
36
-
37
-
38
-
39
- /Users/soichirohara/.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/sshkit-1.21.2/lib/sshkit/command.rb:97:in `exit_status=': rake exit status: 1 (SSHKit::Command::Failed)
40
-
41
- rake stdout: Nothing written
42
-
43
- rake stderr: rake aborted!
44
-
45
- LoadError: libmysqlclient.so.18: cannot open shared object file: No such file or directory - /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/mysql2-0.5.3/lib/mysql2/mysql2.so
46
-
47
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
48
-
49
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
50
-
51
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
52
-
53
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
54
-
55
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
56
-
57
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/activesupport-6.1.3.1/lib/active_support/dependencies.rb:332:in `block in require'
58
-
59
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/activesupport-6.1.3.1/lib/active_support/dependencies.rb:299:in `load_dependency'
60
-
61
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/activesupport-6.1.3.1/lib/active_support/dependencies.rb:332:in `require'
62
-
63
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/mysql2-0.5.3/lib/mysql2.rb:36:in `<main>'
64
-
65
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
66
-
67
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
68
-
69
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
70
-
71
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
72
-
73
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
74
-
75
- /var/www/coffee_passport/releases/20210511045750/config/application.rb:7:in `<top (required)>'
76
-
77
- /var/www/coffee_passport/releases/20210511045750/Rakefile:4:in `require_relative'
78
-
79
- /var/www/coffee_passport/releases/20210511045750/Rakefile:4:in `<top (required)>'
80
-
81
- /var/www/coffee_passport/shared/bundle/ruby/2.6.0/gems/rake-13.0.3/exe/rake:27:in `<top (required)>'
82
-
83
- /home/ec2-user/.rbenv/versions/2.6.5/bin/bundle:23:in `load'
84
-
85
- /home/ec2-user/.rbenv/versions/2.6.5/bin/bundle:23:in `<main>'
86
-
87
- ```
88
-
89
-
90
-
91
- capistrano.log
92
-
93
-
94
-
95
- のエラーログもこんな感じだったので、teratailは1000字以内で入力しなければならないので、必要であれば共有したいと思います。
96
-
97
-
98
-
99
- # 該当のソースコード
100
-
101
-
102
-
103
- **[このアプリのGithub](https://github.com/Harasou21/coffee_passport)**
104
-
105
-
106
-
107
- **database.yml**
108
-
109
-
110
-
111
- ```
112
-
113
- default: &default
114
-
115
- adapter: mysql2
116
-
117
- encoding: utf8
118
-
119
- pool: <%= ENV.fetch("RAILS_MAX_THREADS") { 5 } %>
120
-
121
- username: root
122
-
123
- password: <%= ENV['MYSQL_ROOT_PASSWORD'] %>
124
-
125
- socket: /tmp/mysql.sock
126
-
127
- host: <%= ENV['MYSQL_HOST'] || 'localhost' %>
128
-
129
-
130
-
131
- development:
132
-
133
- <<: *default
134
-
135
- database: coffee_passport_development
136
-
137
-
138
-
139
-
140
-
141
-
142
-
143
- # Warning: The database defined as "test" will be erased and
144
-
145
- # re-generated from your development database when you run "rake".
146
-
147
- # Do not set this db to the same as development or production.
148
-
149
- test:
150
-
151
- <<: *default
152
-
153
- database: coffee_passport_test
154
-
155
-
156
-
157
-
158
-
159
- # As with config/credentials.yml, you never want to store sensitive information,
160
-
161
- # like your database password, in your source code. If your source code is
162
-
163
- # ever seen by anyone, they now have access to your database.
164
-
165
- #
166
-
167
- # Instead, provide the password as a unix environment variable when you boot
168
-
169
- # the app. Read https://guides.rubyonrails.org/configuring.html#configuring-a-database
170
-
171
- # for a full rundown on how to provide these environment variables in a
172
-
173
- # production deployment.
174
-
175
- #
176
-
177
- # On Heroku and other platform providers, you may have a full connection URL
178
-
179
- # available as an environment variable. For example:
180
-
181
- #
182
-
183
- # DATABASE_URL="mysql2://myuser:mypass@localhost/somedatabase"
184
-
185
- #
186
-
187
- # You can use this database configuration with:
188
-
189
- #
190
-
191
- # production:
192
-
193
- # url: <%= ENV['DATABASE_URL'] %>
194
-
195
- #
196
-
197
- production:
198
-
199
- <<: *default
200
-
201
- database: coffee_passport_production
202
-
203
- username: root
204
-
205
- password: <%= ENV['MYSQL_ROOT_PASSWORD'] %>
206
-
207
- host: cp-mysql.c3sv1rwobfad.ap-northeast-1.rds.amazonaws.com
208
-
209
-
210
-
211
- ```
212
-
213
-
214
-
215
- **Gemfile**
216
-
217
-
218
-
219
- ```
220
-
221
- source 'https://rubygems.org'
222
-
223
- git_source(:github) { |repo| "https://github.com/#{repo}.git" }
224
-
225
-
226
-
227
- ruby '2.6.5'
228
-
229
-
230
-
231
- # Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
232
-
233
- gem 'rails', '6.1.3.1'
234
-
235
- # Use mysql as the database for Active Record
236
-
237
- gem 'mysql2', '>= 0.4.4'
238
-
239
- # Use Puma as the app server
240
-
241
- gem 'puma', '~> 3.11'
242
-
243
- # Use SCSS for stylesheets
244
-
245
- gem 'sass-rails', '~> 5'
246
-
247
- # Transpile app-like JavaScript. Read more: https://github.com/rails/webpacker
248
-
249
- gem 'webpacker', '~> 4.0'
250
-
251
- # Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
252
-
253
- gem 'turbolinks', '~> 5'
254
-
255
- # Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
256
-
257
- gem 'jbuilder', '~> 2.7'
258
-
259
- # Use Redis adapter to run Action Cable in production
260
-
261
- # gem 'redis', '~> 4.0'
262
-
263
- # Use Active Model has_secure_password
264
-
265
- gem 'bcrypt', '~> 3.1.7'
266
-
267
-
268
-
269
-
270
-
271
- # Use Active Storage variant
272
-
273
- # gem 'image_processing', '~> 1.2'
274
-
275
-
276
-
277
- # Reduces boot times through caching; required in config/boot.rb
278
-
279
- gem 'bootsnap', '>= 1.4.2', require: false
280
-
281
-
282
-
283
- group :development, :test do
284
-
285
- # Call 'byebug' anywhere in the code to stop execution and get a debugger console
286
-
287
- gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
288
-
289
- gem 'rspec-rails'
290
-
291
- gem 'factory_bot_rails'
292
-
293
- gem 'faker'
294
-
295
- gem 'capistrano'
296
-
297
- gem 'capistrano-rbenv'
298
-
299
- gem 'capistrano-bundler'
300
-
301
- gem 'capistrano-rails'
302
-
303
- gem 'capistrano3-unicorn'
304
-
305
- end
306
-
307
-
308
-
309
- group :development do
310
-
311
- # Access an interactive console on exception pages or by calling 'console' anywhere in the code.
312
-
313
- gem 'web-console', '>= 3.3.0'
314
-
315
- gem 'listen', '>= 3.0.5', '< 3.2'
316
-
317
- # Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
318
-
319
- gem 'spring'
320
-
321
- gem 'spring-watcher-listen', '~> 2.0.0'
322
-
323
- gem 'rubocop', require: false
324
-
325
- end
326
-
327
-
328
-
329
- group :test do
330
-
331
- # Adds support for Capybara system testing and selenium driver
332
-
333
- gem 'capybara', '>= 2.15'
334
-
335
- gem 'selenium-webdriver'
336
-
337
- # Easy installation and use of web drivers to run system tests with browsers
338
-
339
- gem 'webdrivers'
340
-
341
- gem 'launchy'
342
-
343
- end
344
-
345
-
346
-
347
- group :production do
348
-
349
- gem 'unicorn', '5.4.1'
350
-
351
- end
352
-
353
-
354
-
355
- # Windows does not include zoneinfo files, so bundle the tzinfo-data gem
356
-
357
- gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
358
-
359
-
360
-
361
- gem 'pry-rails'
362
-
363
-
364
-
365
- gem "mimemagic"
366
-
367
- gem 'image_processing', '~> 1.2'
368
-
369
- gem 'active_hash'
370
-
371
- gem 'payjp'
372
-
373
- gem 'ransack'
374
-
375
- gem 'will_paginate', '3.1.8'
376
-
377
- gem 'bootstrap-will_paginate', '1.0.0'
378
-
379
- gem "jquery-rails"
380
-
381
- gem 'omniauth-twitter'
382
-
383
- gem 'omniauth-facebook'
384
-
385
- gem 'omniauth-google-oauth2'
386
-
387
- gem 'omniauth-rails_csrf_protection'
388
-
389
- gem 'oauth2'
390
-
391
- gem "aws-sdk-s3", require: false
392
-
393
- gem 'faker'
394
-
395
- gem 'dotenv-rails'
396
-
397
- # rack のアップデートのバグで画像が上手く開いてくれない見たいなので、グレードダウン(近々修正くるらしい)
398
-
399
- gem 'rails-i18n'
400
-
401
- ```
402
-
403
-
404
-
405
-
406
-
407
-
408
-
409
- # 試したこと
410
-
411
-
412
-
413
- 私の行った手順は以下です。
414
-
415
- (1)
416
-
417
-
418
-
419
- ```
420
-
421
- sudo yum install libmysqlclient.so.18
422
-
423
- ```
424
-
425
-
426
-
427
- を実行したら 
428
-
429
-
430
-
431
- ```
432
-
433
- sudo: yum: command not found
434
-
435
- ```
436
-
437
-
438
-
439
- とエラーが出たので
440
-
441
-
442
-
443
- ```
444
-
445
- brew install yum
446
-
447
- ```
448
-
449
-
450
-
451
- を実行。
452
-
453
-
454
-
455
- ```
456
-
457
- ==> Searching for similarly named formulae...
458
-
459
- Error: No similarly named formulae found.
460
-
461
- Error: No available formula or cask with the name "yum".
462
-
463
- ==> Searching for a previously deleted formula (in the last month)...
464
-
465
- Error: No previously deleted formula found.
466
-
467
- ==> Searching taps on GitHub...
468
-
469
- Error: No formulae found in taps.
470
-
471
-
472
-
473
- ```
474
-
475
-
476
-
477
- ```
478
-
479
- docker-compose exec web apt-get install libmysqlclient.so.18
480
-
481
- ```
482
-
483
- を実行したら
484
-
485
529
  ```
486
530
 
487
531
  Reading package lists... Done

1

情報の追加

2021/05/11 06:58

投稿

divclass123
divclass123

スコア35

test CHANGED
File without changes
test CHANGED
@@ -18,6 +18,10 @@
18
18
 
19
19
 
20
20
 
21
+ RDSのMySQLは8系でdocker開発環境は5.7なのでそこら辺も関係あるかもしれません。
22
+
23
+
24
+
21
25
  を実行したら
22
26
 
23
27
 
@@ -566,4 +570,8 @@
566
570
 
567
571
 
568
572
 
573
+
574
+
575
+
576
+
569
577
  そもそも、本番環境のデータベース はRDSなので、自分のアプローチが何か間違ってるかもしれません。。。