
capistrano를 통해 내 앱을 배포하려고 합니다. 완료되었지만 nginx를 시작하고 브라우저에 내 사이트를 표시하면 '죄송합니다. 문제가 발생했습니다.'
그것은 나쁘다. 저는 유니콘을 사용합니다. 내 구성 보기https://gist.github.com/3904032
나는 를 통해 서버를 시작하려고 시도했는데 rails s -e prodiction
작동했습니다!
서버를 다시 시작할 수 없기 때문에 이 오류가 발생하는 것 같습니다.
root@li272-194:~# /etc/init.d/nginx restart
Restarting nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
configuration file /etc/nginx/nginx.conf test is successful
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
[emerg]: bind() to 0.0.0.0:80 failed (98: Address already in use)
[emerg]: still could not bind()
nginx.
어떤 아이디어가 있나요?
nginx 로그
2012/10/17 02:57:41 [error] 3271#0: *1 could not find named location "@myapp", client: 91.192.62.77, server: 178.79.153.194, request: "GET / HTTP/1.1", host: "178.79.153.194"
2012/10/17 02:19:08 [crit] 2448#0: *8 connect() to unix:/srv/zarcon/shared/unicorn.sock failed (2: No such file or directory) while connecting to upstream, client: 91.192.62.77, server: zarkon, request:
"GET / HTTP/1.1", upstream: "http://unix:/srv/zarcon/shared/unicorn.sock:/", host: "178.79.153.194"
답변1
nginx 구성의 32번째 줄은 다음을 참조하세요.@myapp
try_files $uri/index.html $uri.html $uri @myapp;
을(를) 참조하려고 하신 건가요 @zarkon
?
try_files $uri/index.html $uri.html $uri @zarkon;
그리고 커밋 pid /tmp/nginx.pid;
문자열