teratail header banner
teratail header banner
質問するログイン新規登録

質問編集履歴

2

config.ruの追加

2020/07/07 03:59

投稿

sakanafuto
sakanafuto

スコア0

title CHANGED
File without changes
body CHANGED
@@ -198,5 +198,16 @@
198
198
  }
199
199
  ```
200
200
 
201
+ `config.ru`です
201
202
 
203
+ ```
204
+ # This file is used by Rack-based servers to start the application.
205
+
206
+ require_relative 'config/environment'
207
+
208
+ run Rails.application
209
+
210
+ ```
211
+
212
+
202
213
  エラーの意味だけでも教えていただけたら幸いです。。。

1

/etc/nginx/conf.d/Stelle.confの追加

2020/07/07 03:59

投稿

sakanafuto
sakanafuto

スコア0

title CHANGED
File without changes
body CHANGED
@@ -169,4 +169,34 @@
169
169
  }
170
170
  ```
171
171
 
172
+ 本命である`/etc/nginx/conf.d/Stelle.conf`です
173
+
174
+ ```
175
+ error_log /var/www/rails/stelle/current/log/nginx.error.log;
176
+ access_log /var/www/rails/stelle/current/log/nginx.access.log;
177
+ client_max_body_size 2G;
178
+ upstream app_server {
179
+ server unix:/var/www/rails/stelle/current/tmp/sockets/.unicorn.sock fail_timeout=0;
180
+ }
181
+ server {
182
+ listen 80;
183
+ server_name 3.xxx.xxx.xx;
184
+ keepalive_timeout 5;
185
+ root /var/www/rails/stelle/current/public;
186
+ try_files $uri/index.html $uri.html $uri @app;
187
+ location @app {
188
+ # HTTP headers
189
+ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
190
+ proxy_set_header Host $http_host;
191
+ proxy_redirect off;
192
+ proxy_pass http://app_server;
193
+ }
194
+ error_page 500 502 503 504 /500.html;
195
+ location = /500.html {
196
+ root /var/www/rails/stelle/current/public;
197
+ }
198
+ }
199
+ ```
200
+
201
+
172
202
  エラーの意味だけでも教えていただけたら幸いです。。。