質問編集履歴
1
詳細情報付加
test
CHANGED
File without changes
|
test
CHANGED
@@ -121,3 +121,115 @@
|
|
121
121
|
|
122
122
|
|
123
123
|
File.openのあたりがダメなのかなとはわかっているのですが、手がかりがなく途方に暮れています。どなたかよろしくお願いします。
|
124
|
+
|
125
|
+
|
126
|
+
|
127
|
+
【追記】EC2のディレクトリ状況
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
```csh
|
132
|
+
|
133
|
+
[ec2-user@ip-172-31-8-184 current]$ ls
|
134
|
+
|
135
|
+
Gemfile README.rdoc app bin config.ru lib public tmp
|
136
|
+
|
137
|
+
Gemfile.lock Rakefile area_id config db log test vendor
|
138
|
+
|
139
|
+
[ec2-user@ip-172-31-8-184 current]$ cd tmp
|
140
|
+
|
141
|
+
[ec2-user@ip-172-31-8-184 tmp]$ ls -la
|
142
|
+
|
143
|
+
合計 16
|
144
|
+
|
145
|
+
drwxr-xr-x 4 webapp webapp 4096 7月 20 00:46 .
|
146
|
+
|
147
|
+
drwxr-xr-x 13 webapp webapp 4096 7月 20 00:46 ..
|
148
|
+
|
149
|
+
drwxr-xr-x 3 webapp webapp 4096 7月 20 00:44 cache
|
150
|
+
|
151
|
+
drwxr-xr-x 2 webapp webapp 4096 7月 20 06:25 files
|
152
|
+
|
153
|
+
[ec2-user@ip-172-31-8-184 tmp]$ pwd
|
154
|
+
|
155
|
+
/var/app/current/tmp
|
156
|
+
|
157
|
+
```
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
log/production.logの抜粋はこちらです。
|
162
|
+
|
163
|
+
|
164
|
+
|
165
|
+
```log
|
166
|
+
|
167
|
+
I, [2016-07-20T06:25:32.056814 #22912] INFO -- : Parameters: {"utf8"=>"✓", "authenticity_token"=>"VeWAmjaeUgNtASnWcPmJgWikufWhfZc5XVKwCmAjQ2zlXWbQRaieWKhbh9N32TN7A9wS9btqOyHHtF6xgtSyDA==", "review"=>{"title"=>"test0720 1525", "food_rating"=>"1", "decor_rating"=>"1", "service_rating"=>"1", "comment"=>"hahahah", "file"=>#<ActionDispatch::Http::UploadedFile:0x007f2bf50dd900 @tempfile=#<Tempfile:/tmp/RackMultipart20160720-22912-vflx9p.png>, @original_filename="スコア履歴詳細0720.png", @content_type="image/png", @headers="Content-Disposition: form-data; name=\"review[file]\"; filename=\"\xE3\x82\xB9\xE3\x82\xB3\xE3\x82\xA2\xE5\xB1\xA5\xE6\xAD\xB4\xE8\xA9\xB3\xE7\xB4\xB00720.png\"\r\nContent-Type: image/png\r\n">, "restaurant_id"=>"26", "user_id"=>"8"}, "commit"=>"Create Review", "locale"=>"en"}
|
168
|
+
|
169
|
+
D, [2016-07-20T06:25:32.060935 #22912] DEBUG -- : ^[[1m^[[36m (0.7ms)^[[0m ^[[1mBEGIN^[[0m
|
170
|
+
|
171
|
+
D, [2016-07-20T06:25:32.090755 #22912] DEBUG -- : ^[[1m^[[35mSQL (27.8ms)^[[0m INSERT INTO `reviews` (`restaurant_id`, `user_id`, `food_rating`, `decor_rating`, `service_rating`, `title`, `comment`, `image1`, `created_at`, `updated_at`) VALUES (26, 8, 1, 1, 1, 'test0720 1525', 'hahahah', 'review/894a32b74b99b14a55d2d0d4ea44c511.png', '2016-07-20 06:25:32', '2016-07-20 06:25:32')
|
172
|
+
|
173
|
+
I, [2016-07-20T06:25:32.768627 #22912] INFO -- : Started GET "/images/review/894a32b74b99b14a55d2d0d4ea44c511.png" for 118.238.219.183 at 2016-07-20 06:25:32 +0000
|
174
|
+
|
175
|
+
F, [2016-07-20T06:25:32.770916 #22912] FATAL -- :
|
176
|
+
|
177
|
+
ActionController::RoutingError (No route matches [GET] "/images/review/894a32b74b99b14a55d2d0d4ea44c511.png"):
|
178
|
+
|
179
|
+
actionpack (4.2.3) lib/action_dispatch/middleware/debug_exceptions.rb:21:in `call'
|
180
|
+
|
181
|
+
actionpack (4.2.3) lib/action_dispatch/middleware/show_exceptions.rb:30:in `call'
|
182
|
+
|
183
|
+
railties (4.2.3) lib/rails/rack/logger.rb:38:in `call_app'
|
184
|
+
|
185
|
+
railties (4.2.3) lib/rails/rack/logger.rb:20:in `block in call'
|
186
|
+
|
187
|
+
activesupport (4.2.3) lib/active_support/tagged_logging.rb:68:in `block in tagged'
|
188
|
+
|
189
|
+
activesupport (4.2.3) lib/active_support/tagged_logging.rb:26:in `tagged'
|
190
|
+
|
191
|
+
activesupport (4.2.3) lib/active_support/tagged_logging.rb:68:in `tagged'
|
192
|
+
|
193
|
+
railties (4.2.3) lib/rails/rack/logger.rb:20:in `call'
|
194
|
+
|
195
|
+
actionpack (4.2.3) lib/action_dispatch/middleware/request_id.rb:21:in `call'
|
196
|
+
|
197
|
+
rack (1.6.4) lib/rack/methodoverride.rb:22:in `call'
|
198
|
+
|
199
|
+
rack (1.6.4) lib/rack/runtime.rb:18:in `call'
|
200
|
+
|
201
|
+
activesupport (4.2.3) lib/active_support/cache/strategy/local_cache_middleware
|
202
|
+
|
203
|
+
.rb:28:in `call'
|
204
|
+
|
205
|
+
activesupport (4.2.3) lib/active_support/cache/strategy/local_cache_middleware.rb:28:in `call'
|
206
|
+
|
207
|
+
rack (1.6.4) lib/rack/sendfile.rb:113:in `call'
|
208
|
+
|
209
|
+
railties (4.2.3) lib/rails/engine.rb:518:in `call'
|
210
|
+
|
211
|
+
railties (4.2.3) lib/rails/application.rb:165:in `call'
|
212
|
+
|
213
|
+
passenger (4.0.60) lib/phusion_passenger/rack/thread_handler_extension.rb:74:in `process_request'
|
214
|
+
|
215
|
+
passenger (4.0.60) lib/phusion_passenger/request_handler/thread_handler.rb:141:in `accept_and_process_next_request'
|
216
|
+
|
217
|
+
passenger (4.0.60) lib/phusion_passenger/request_handler/thread_handler.rb:109:in `main_loop'
|
218
|
+
|
219
|
+
passenger (4.0.60) lib/phusion_passenger/request_handler.rb:455:in `block (3 levels) in start_threads'
|
220
|
+
|
221
|
+
I, [2016-07-20T06:26:21.832915 #22912] INFO -- : Started GET "/" for 150.70.173.8 at 2016-07-20 06:26:21 +0000
|
222
|
+
|
223
|
+
I, [2016-07-20T06:26:21.835259 #22912] INFO -- : Processing by FrontpageController#index as */*
|
224
|
+
|
225
|
+
I, [2016-07-20T06:26:21.850473 #22912] INFO -- : Rendered frontpage/index.html.slim within layouts/application (8.8ms)
|
226
|
+
|
227
|
+
I, [2016-07-20T06:26:21.853794 #22912
|
228
|
+
|
229
|
+
```
|
230
|
+
|
231
|
+
|
232
|
+
|
233
|
+
画像がアップロードされず、app/assets/images配下にもコピー出来ないため画面上はこのようになっております。
|
234
|
+
|
235
|
+
![no photo](96fd710094563aae891beee711b5d731.png)
|