質問編集履歴
4
railsのエラーログを追記しました。
test
CHANGED
File without changes
|
test
CHANGED
@@ -161,3 +161,19 @@
|
|
161
161
|
}
|
162
162
|
|
163
163
|
```
|
164
|
+
|
165
|
+
|
166
|
+
|
167
|
+
railsのエラーログ
|
168
|
+
|
169
|
+
|
170
|
+
|
171
|
+
```
|
172
|
+
|
173
|
+
I, [2021-07-16T07:35:06.756202 #1] INFO -- : [dba872fa-ea06-492c-86e7-c085d25ae80e] Started GET "/" for 118.105.181.146 at 2021-07-16 07:35:06 +0000
|
174
|
+
|
175
|
+
F, [2021-07-16T07:35:06.756598 #1] FATAL -- : [dba872fa-ea06-492c-86e7-c085d25ae80e]
|
176
|
+
|
177
|
+
[dba872fa-ea06-492c-86e7-c085d25ae80e] ActionController::RoutingError (No route matches [GET] "/"):
|
178
|
+
|
179
|
+
```
|
3
nginxの設定を追記しました。
test
CHANGED
File without changes
|
test
CHANGED
@@ -99,3 +99,65 @@
|
|
99
99
|
external: true
|
100
100
|
|
101
101
|
```
|
102
|
+
|
103
|
+
|
104
|
+
|
105
|
+
nginx.conf
|
106
|
+
|
107
|
+
|
108
|
+
|
109
|
+
```
|
110
|
+
|
111
|
+
upstream saving {
|
112
|
+
|
113
|
+
server unix:///saving/tmp/sockets/puma.sock;
|
114
|
+
|
115
|
+
}
|
116
|
+
|
117
|
+
|
118
|
+
|
119
|
+
server {
|
120
|
+
|
121
|
+
listen 80;
|
122
|
+
|
123
|
+
server_name 35.74.55.100;
|
124
|
+
|
125
|
+
|
126
|
+
|
127
|
+
access_log /var/log/nginx/access.log;
|
128
|
+
|
129
|
+
error_log /var/log/nginx/error.log;
|
130
|
+
|
131
|
+
|
132
|
+
|
133
|
+
root /saving/public;
|
134
|
+
|
135
|
+
|
136
|
+
|
137
|
+
client_max_body_size 100m;
|
138
|
+
|
139
|
+
error_page 404 /404.html;
|
140
|
+
|
141
|
+
error_page 505 502 503 504 /500.html;
|
142
|
+
|
143
|
+
try_files $uri/index.html $uri @saving;
|
144
|
+
|
145
|
+
keepalive_timeout 5;
|
146
|
+
|
147
|
+
|
148
|
+
|
149
|
+
location @saving {
|
150
|
+
|
151
|
+
proxy_set_header X-Real-IP $remote_addr;
|
152
|
+
|
153
|
+
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
154
|
+
|
155
|
+
proxy_set_header Host $http_host;
|
156
|
+
|
157
|
+
proxy_pass http://saving;
|
158
|
+
|
159
|
+
}
|
160
|
+
|
161
|
+
}
|
162
|
+
|
163
|
+
```
|
2
docker-composeのコードを追記
test
CHANGED
File without changes
|
test
CHANGED
@@ -17,3 +17,85 @@
|
|
17
17
|
|
18
18
|
|
19
19
|
![イメージ説明](9400cfb8e4c4e5ab01084ebc50eaa606.png)
|
20
|
+
|
21
|
+
|
22
|
+
|
23
|
+
docker-compose
|
24
|
+
|
25
|
+
|
26
|
+
|
27
|
+
```
|
28
|
+
|
29
|
+
version: '3'
|
30
|
+
|
31
|
+
services:
|
32
|
+
|
33
|
+
app:
|
34
|
+
|
35
|
+
build:
|
36
|
+
|
37
|
+
context: .
|
38
|
+
|
39
|
+
entrypoint: bundle exec puma -C config/puma.rb -e production
|
40
|
+
|
41
|
+
volumes:
|
42
|
+
|
43
|
+
- .:/saving
|
44
|
+
|
45
|
+
- public-data:/saving/public
|
46
|
+
|
47
|
+
- tmp-data:/saving/tmp
|
48
|
+
|
49
|
+
- log-data:/saving/log
|
50
|
+
|
51
|
+
networks:
|
52
|
+
|
53
|
+
- saving-network
|
54
|
+
|
55
|
+
|
56
|
+
|
57
|
+
web:
|
58
|
+
|
59
|
+
build:
|
60
|
+
|
61
|
+
context: ./nginx_docker
|
62
|
+
|
63
|
+
volumes:
|
64
|
+
|
65
|
+
- public-data:/saving/public
|
66
|
+
|
67
|
+
- tmp-data:/saving/tmp
|
68
|
+
|
69
|
+
ports:
|
70
|
+
|
71
|
+
- 80:80
|
72
|
+
|
73
|
+
depends_on:
|
74
|
+
|
75
|
+
- app
|
76
|
+
|
77
|
+
networks:
|
78
|
+
|
79
|
+
- saving-network
|
80
|
+
|
81
|
+
volumes:
|
82
|
+
|
83
|
+
public-data:
|
84
|
+
|
85
|
+
|
86
|
+
|
87
|
+
tmp-data:
|
88
|
+
|
89
|
+
log-data:
|
90
|
+
|
91
|
+
db-data:
|
92
|
+
|
93
|
+
|
94
|
+
|
95
|
+
networks:
|
96
|
+
|
97
|
+
saving-network:
|
98
|
+
|
99
|
+
external: true
|
100
|
+
|
101
|
+
```
|
1
画像を変更
test
CHANGED
File without changes
|
test
CHANGED
@@ -16,4 +16,4 @@
|
|
16
16
|
|
17
17
|
|
18
18
|
|
19
|
-
![イメージ説明](
|
19
|
+
![イメージ説明](9400cfb8e4c4e5ab01084ebc50eaa606.png)
|