質問編集履歴

3

修正

2020/09/03 21:11

投稿

tomsuma
tomsuma

スコア38

test CHANGED
File without changes
test CHANGED
@@ -48,8 +48,6 @@
48
48
 
49
49
  webpacker.yml
50
50
 
51
-
52
-
53
51
  # Note: You must restart bin/webpack-dev-server for changes to take effect
54
52
 
55
53
 
@@ -66,7 +64,7 @@
66
64
 
67
65
  cache_path: tmp/cache/webpacker
68
66
 
69
- check_yarn_integrity: false  エラー原因
67
+ check_yarn_integrity: false
70
68
 
71
69
  webpack_compile_output: true
72
70
 
@@ -160,7 +158,7 @@
160
158
 
161
159
  # Verifies that correct packages and versions are installed by inspecting package.json, yarn.lock, and node_modules
162
160
 
163
- check_yarn_integrity: true
161
+ check_yarn_integrity: false
164
162
 
165
163
 
166
164
 
@@ -244,6 +242,8 @@
244
242
 
245
243
 
246
244
 
245
+
246
+
247
247
  ```
248
248
 
249
249
  docker-compose upを打つと起こるエラー

2

修正

2020/09/03 21:11

投稿

tomsuma
tomsuma

スコア38

test CHANGED
@@ -1 +1 @@
1
- Dockerにてwebpackerエラー
1
+ check_yarn_integrityをfalseエラーが消えない
test CHANGED
@@ -6,17 +6,9 @@
6
6
 
7
7
 
8
8
 
9
- docker-compose exec web bundle exec rake db:create
9
+ docker-compose upを打つとエラーが起こります
10
-
11
- コマンドを打つと
10
+
12
-
13
- このようなエラーが出て詰まってます。
11
+
14
-
15
- ```
16
-
17
- ERROR: No container found for web_1
18
-
19
- ```
20
12
 
21
13
  試したこと
22
14
 
@@ -44,216 +36,222 @@
44
36
 
45
37
 
46
38
 
39
+
40
+
41
+
42
+
43
+
44
+
45
+
46
+
47
+ ```
48
+
49
+ webpacker.yml
50
+
51
+
52
+
53
+ # Note: You must restart bin/webpack-dev-server for changes to take effect
54
+
55
+
56
+
57
+ default: &default
58
+
59
+ source_path: app/javascript
60
+
61
+ source_entry_path: packs
62
+
63
+ public_root_path: public
64
+
65
+ public_output_path: packs
66
+
67
+ cache_path: tmp/cache/webpacker
68
+
69
+ check_yarn_integrity: false  エラー原因
70
+
71
+ webpack_compile_output: true
72
+
73
+
74
+
75
+ # Additional paths webpack should lookup modules
76
+
77
+ # ['app/assets', 'engine/foo/app/assets']
78
+
79
+ resolved_paths: []
80
+
81
+
82
+
83
+ # Reload manifest.json on all requests so we reload latest compiled packs
84
+
85
+ cache_manifest: false
86
+
87
+
88
+
89
+ # Extract and emit a css file
90
+
91
+ extract_css: false
92
+
93
+
94
+
95
+ static_assets_extensions:
96
+
97
+ - .jpg
98
+
99
+ - .jpeg
100
+
101
+ - .png
102
+
103
+ - .gif
104
+
105
+ - .tiff
106
+
107
+ - .ico
108
+
109
+ - .svg
110
+
111
+ - .eot
112
+
113
+ - .otf
114
+
115
+ - .ttf
116
+
117
+ - .woff
118
+
119
+ - .woff2
120
+
121
+
122
+
123
+ extensions:
124
+
125
+ - .mjs
126
+
127
+ - .js
128
+
129
+ - .sass
130
+
131
+ - .scss
132
+
133
+ - .css
134
+
135
+ - .module.sass
136
+
137
+ - .module.scss
138
+
139
+ - .module.css
140
+
141
+ - .png
142
+
143
+ - .svg
144
+
145
+ - .gif
146
+
147
+ - .jpeg
148
+
149
+ - .jpg
150
+
151
+
152
+
153
+ development:
154
+
155
+ <<: *default
156
+
157
+ compile: true
158
+
159
+
160
+
161
+ # Verifies that correct packages and versions are installed by inspecting package.json, yarn.lock, and node_modules
162
+
163
+ check_yarn_integrity: true
164
+
165
+
166
+
167
+ # Reference: https://webpack.js.org/configuration/dev-server/
168
+
169
+ dev_server:
170
+
171
+ https: false
172
+
173
+ host: localhost
174
+
175
+ port: 3035
176
+
177
+ public: localhost:3035
178
+
179
+ hmr: false
180
+
181
+ # Inline should be set to true if using HMR
182
+
183
+ inline: true
184
+
185
+ overlay: true
186
+
187
+ compress: true
188
+
189
+ disable_host_check: true
190
+
191
+ use_local_ip: false
192
+
193
+ quiet: false
194
+
195
+ pretty: false
196
+
197
+ headers:
198
+
199
+ 'Access-Control-Allow-Origin': '*'
200
+
201
+ watch_options:
202
+
203
+ ignored: '**/node_modules/**'
204
+
205
+
206
+
207
+
208
+
209
+ test:
210
+
211
+ <<: *default
212
+
213
+ compile: true
214
+
215
+
216
+
217
+ # Compile test packs to a separate directory
218
+
219
+ public_output_path: packs-test
220
+
221
+
222
+
223
+ production:
224
+
225
+ <<: *default
226
+
227
+
228
+
229
+ # Production depends on precompilation of packs prior to booting for performance.
230
+
231
+ compile: false
232
+
233
+
234
+
235
+ # Extract and emit a css file
236
+
237
+ extract_css: true
238
+
239
+
240
+
241
+ # Cache manifest.json for performance
242
+
243
+ cache_manifest: true
244
+
245
+
246
+
247
+ ```
248
+
47
249
  docker-compose upを打つと起こるエラー
48
250
 
49
251
 
50
252
 
51
253
  ```
52
254
 
53
- webpacker.yml
54
-
55
-
56
-
57
- # Note: You must restart bin/webpack-dev-server for changes to take effect
58
-
59
-
60
-
61
- default: &default
62
-
63
- source_path: app/javascript
64
-
65
- source_entry_path: packs
66
-
67
- public_root_path: public
68
-
69
- public_output_path: packs
70
-
71
- cache_path: tmp/cache/webpacker
72
-
73
- check_yarn_integrity: false  エラー原因
74
-
75
- webpack_compile_output: true
76
-
77
-
78
-
79
- # Additional paths webpack should lookup modules
80
-
81
- # ['app/assets', 'engine/foo/app/assets']
82
-
83
- resolved_paths: []
84
-
85
-
86
-
87
- # Reload manifest.json on all requests so we reload latest compiled packs
88
-
89
- cache_manifest: false
90
-
91
-
92
-
93
- # Extract and emit a css file
94
-
95
- extract_css: false
96
-
97
-
98
-
99
- static_assets_extensions:
100
-
101
- - .jpg
102
-
103
- - .jpeg
104
-
105
- - .png
106
-
107
- - .gif
108
-
109
- - .tiff
110
-
111
- - .ico
112
-
113
- - .svg
114
-
115
- - .eot
116
-
117
- - .otf
118
-
119
- - .ttf
120
-
121
- - .woff
122
-
123
- - .woff2
124
-
125
-
126
-
127
- extensions:
128
-
129
- - .mjs
130
-
131
- - .js
132
-
133
- - .sass
134
-
135
- - .scss
136
-
137
- - .css
138
-
139
- - .module.sass
140
-
141
- - .module.scss
142
-
143
- - .module.css
144
-
145
- - .png
146
-
147
- - .svg
148
-
149
- - .gif
150
-
151
- - .jpeg
152
-
153
- - .jpg
154
-
155
-
156
-
157
- development:
158
-
159
- <<: *default
160
-
161
- compile: true
162
-
163
-
164
-
165
- # Verifies that correct packages and versions are installed by inspecting package.json, yarn.lock, and node_modules
166
-
167
- check_yarn_integrity: true
168
-
169
-
170
-
171
- # Reference: https://webpack.js.org/configuration/dev-server/
172
-
173
- dev_server:
174
-
175
- https: false
176
-
177
- host: localhost
178
-
179
- port: 3035
180
-
181
- public: localhost:3035
182
-
183
- hmr: false
184
-
185
- # Inline should be set to true if using HMR
186
-
187
- inline: true
188
-
189
- overlay: true
190
-
191
- compress: true
192
-
193
- disable_host_check: true
194
-
195
- use_local_ip: false
196
-
197
- quiet: false
198
-
199
- pretty: false
200
-
201
- headers:
202
-
203
- 'Access-Control-Allow-Origin': '*'
204
-
205
- watch_options:
206
-
207
- ignored: '**/node_modules/**'
208
-
209
-
210
-
211
-
212
-
213
- test:
214
-
215
- <<: *default
216
-
217
- compile: true
218
-
219
-
220
-
221
- # Compile test packs to a separate directory
222
-
223
- public_output_path: packs-test
224
-
225
-
226
-
227
- production:
228
-
229
- <<: *default
230
-
231
-
232
-
233
- # Production depends on precompilation of packs prior to booting for performance.
234
-
235
- compile: false
236
-
237
-
238
-
239
- # Extract and emit a css file
240
-
241
- extract_css: true
242
-
243
-
244
-
245
- # Cache manifest.json for performance
246
-
247
- cache_manifest: true
248
-
249
-
250
-
251
- ```
252
-
253
-
254
-
255
- ```
256
-
257
255
  web_1 | => Booting Puma
258
256
 
259
257
  web_1 | => Rails 6.0.3.2 application starting in development
@@ -297,3 +295,49 @@
297
295
  books_web_1 exited with code 1
298
296
 
299
297
  ```
298
+
299
+
300
+
301
+ また同じく
302
+
303
+ docker-compose run web bundle exec rake db:migrate
304
+
305
+ docker-compose run web bundle exec rake db:create
306
+
307
+ コマンドでも
308
+
309
+
310
+
311
+ ```
312
+
313
+ Starting books_db_1 ... done
314
+
315
+ Creating books_web_run ... done
316
+
317
+ sh: 1: yarn: not found
318
+
319
+
320
+
321
+
322
+
323
+ ========================================
324
+
325
+ Your Yarn packages are out of date!
326
+
327
+ Please run `yarn install --check-files` to update.
328
+
329
+ ========================================
330
+
331
+
332
+
333
+
334
+
335
+ To disable this check, please change `check_yarn_integrity`
336
+
337
+ to `false` in your webpacker config file (config/webpacker.yml).
338
+
339
+
340
+
341
+ ```
342
+
343
+ と出ます

1

修正

2020/09/03 12:57

投稿

tomsuma
tomsuma

スコア38

test CHANGED
File without changes
test CHANGED
@@ -6,15 +6,19 @@
6
6
 
7
7
 
8
8
 
9
- docker-compose up
9
+ docker-compose exec web bundle exec rake db:create
10
10
 
11
11
  コマンドを打つと
12
12
 
13
13
  このようなエラーが出て詰まってます。
14
14
 
15
-
15
+ ```
16
+
16
-
17
+ ERROR: No container found for web_1
18
+
17
-
19
+ ```
20
+
21
+ 試したこと
18
22
 
19
23
  yarn update
20
24
 
@@ -40,7 +44,7 @@
40
44
 
41
45
 
42
46
 
43
-
47
+ docker-compose upを打つと起こるエラー
44
48
 
45
49
 
46
50