質問編集履歴
2
再修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -183,3 +183,115 @@
|
|
183
183
|
|
184
184
|
|
185
185
|
```
|
186
|
+
|
187
|
+
|
188
|
+
|
189
|
+
更に修正版
|
190
|
+
|
191
|
+
```ここに言語を入力
|
192
|
+
|
193
|
+
|
194
|
+
|
195
|
+
user nginx;
|
196
|
+
|
197
|
+
worker_processes 1;
|
198
|
+
|
199
|
+
|
200
|
+
|
201
|
+
error_log /var/log/nginx/error.log warn;
|
202
|
+
|
203
|
+
pid /var/run/nginx.pid;
|
204
|
+
|
205
|
+
|
206
|
+
|
207
|
+
|
208
|
+
|
209
|
+
events {
|
210
|
+
|
211
|
+
worker_connections 1024;
|
212
|
+
|
213
|
+
}
|
214
|
+
|
215
|
+
|
216
|
+
|
217
|
+
|
218
|
+
|
219
|
+
http {
|
220
|
+
|
221
|
+
include /etc/nginx/mime.types;
|
222
|
+
|
223
|
+
default_type application/octet-stream;
|
224
|
+
|
225
|
+
|
226
|
+
|
227
|
+
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
|
228
|
+
|
229
|
+
'$status $body_bytes_sent "$http_referer" '
|
230
|
+
|
231
|
+
'"$http_user_agent" "$http_x_forwarded_for"';
|
232
|
+
|
233
|
+
|
234
|
+
|
235
|
+
access_log /var/log/nginx/access.log main;
|
236
|
+
|
237
|
+
|
238
|
+
|
239
|
+
sendfile on;
|
240
|
+
|
241
|
+
#tcp_nopush on;
|
242
|
+
|
243
|
+
|
244
|
+
|
245
|
+
keepalive_timeout 65;
|
246
|
+
|
247
|
+
|
248
|
+
|
249
|
+
#gzip on;
|
250
|
+
|
251
|
+
|
252
|
+
|
253
|
+
include /etc/nginx/conf.d/*.conf;
|
254
|
+
|
255
|
+
|
256
|
+
|
257
|
+
|
258
|
+
|
259
|
+
|
260
|
+
|
261
|
+
|
262
|
+
|
263
|
+
}
|
264
|
+
|
265
|
+
|
266
|
+
|
267
|
+
stream {
|
268
|
+
|
269
|
+
upstream backend {
|
270
|
+
|
271
|
+
server 127.0.0.1:9090;
|
272
|
+
|
273
|
+
}
|
274
|
+
|
275
|
+
|
276
|
+
|
277
|
+
server {
|
278
|
+
|
279
|
+
listen 443 ssl;
|
280
|
+
|
281
|
+
ssl_certificate /root/SSL/server.crt;
|
282
|
+
|
283
|
+
ssl_certificate_key /root/SSL/XXXX.com.2017.key;
|
284
|
+
|
285
|
+
proxy_connect_timeout 10s;
|
286
|
+
|
287
|
+
proxy_timeout 10s;
|
288
|
+
|
289
|
+
proxy_pass backend;
|
290
|
+
|
291
|
+
}
|
292
|
+
|
293
|
+
|
294
|
+
|
295
|
+
}
|
296
|
+
|
297
|
+
```
|
1
コード修正版追加
test
CHANGED
File without changes
|
test
CHANGED
@@ -61,3 +61,125 @@
|
|
61
61
|
多少は予想していましたが、やはり動かず、基本的なところがわかっていないのですが、
|
62
62
|
|
63
63
|
どのようにすれば良いのか教えて頂きたくよろしくお願いします。
|
64
|
+
|
65
|
+
(追記)
|
66
|
+
|
67
|
+
|
68
|
+
|
69
|
+
編集後、設定は下記の通りとなっています。
|
70
|
+
|
71
|
+
```ここに言語を入力
|
72
|
+
|
73
|
+
user nginx;
|
74
|
+
|
75
|
+
worker_processes 1;
|
76
|
+
|
77
|
+
|
78
|
+
|
79
|
+
error_log /var/log/nginx/error.log warn;
|
80
|
+
|
81
|
+
pid /var/run/nginx.pid;
|
82
|
+
|
83
|
+
|
84
|
+
|
85
|
+
|
86
|
+
|
87
|
+
events {
|
88
|
+
|
89
|
+
worker_connections 1024;
|
90
|
+
|
91
|
+
}
|
92
|
+
|
93
|
+
|
94
|
+
|
95
|
+
|
96
|
+
|
97
|
+
http {
|
98
|
+
|
99
|
+
include /etc/nginx/mime.types;
|
100
|
+
|
101
|
+
default_type application/octet-stream;
|
102
|
+
|
103
|
+
|
104
|
+
|
105
|
+
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
|
106
|
+
|
107
|
+
'$status $body_bytes_sent "$http_referer" '
|
108
|
+
|
109
|
+
'"$http_user_agent" "$http_x_forwarded_for"';
|
110
|
+
|
111
|
+
|
112
|
+
|
113
|
+
access_log /var/log/nginx/access.log main;
|
114
|
+
|
115
|
+
|
116
|
+
|
117
|
+
sendfile on;
|
118
|
+
|
119
|
+
#tcp_nopush on;
|
120
|
+
|
121
|
+
|
122
|
+
|
123
|
+
keepalive_timeout 65;
|
124
|
+
|
125
|
+
|
126
|
+
|
127
|
+
#gzip on;
|
128
|
+
|
129
|
+
|
130
|
+
|
131
|
+
include /etc/nginx/conf.d/*.conf;
|
132
|
+
|
133
|
+
|
134
|
+
|
135
|
+
|
136
|
+
|
137
|
+
stream {
|
138
|
+
|
139
|
+
upstream backend {
|
140
|
+
|
141
|
+
server 127.0.0.1:9090;
|
142
|
+
|
143
|
+
}
|
144
|
+
|
145
|
+
|
146
|
+
|
147
|
+
server {
|
148
|
+
|
149
|
+
listen 443 ssl;
|
150
|
+
|
151
|
+
ssl_certificate /root/SSL/server.crt;
|
152
|
+
|
153
|
+
ssl_certificate_key /root/SSL/XXXXX.com.2017.key;
|
154
|
+
|
155
|
+
proxy_connect_timeout 10s;
|
156
|
+
|
157
|
+
proxy_timeout 10s;
|
158
|
+
|
159
|
+
|
160
|
+
|
161
|
+
|
162
|
+
|
163
|
+
location / {
|
164
|
+
|
165
|
+
proxy_pass backend;
|
166
|
+
|
167
|
+
proxy_http_version 1.1;
|
168
|
+
|
169
|
+
proxy_set_header Upgrade $http_upgrade;
|
170
|
+
|
171
|
+
proxy_set_header Connection "upgrade";
|
172
|
+
|
173
|
+
}
|
174
|
+
|
175
|
+
}
|
176
|
+
|
177
|
+
}
|
178
|
+
|
179
|
+
|
180
|
+
|
181
|
+
}
|
182
|
+
|
183
|
+
|
184
|
+
|
185
|
+
```
|