Skip to content

Instantly share code, notes, and snippets.

Created August 10, 2010 22:12
Show Gist options
  • Select an option

  • Save anonymous/518113 to your computer and use it in GitHub Desktop.

Select an option

Save anonymous/518113 to your computer and use it in GitHub Desktop.
[Tue, 10 Aug 2010 21:47:34 GMT] [debug] [<0.7376.0>] 'GET' /test1/ {1,0}
Headers: [{'Accept',"application/json"},
{'Accept-Encoding',"gzip"},
{'Authorization',"Basic am9jaGVuOmphd29zaXM5"},
{'Connection',"close"},
{'Host',"204.232.210.206:5984"},
{'User-Agent',"CouchDB/0.11.1"},
{'X-Forwarded-For',"201.215.36.77"},
{"X-Real-Ip","201.215.36.77"}]
[Tue, 10 Aug 2010 21:47:34 GMT] [info] [<0.7376.0>] 201.215.36.77 - - 'GET' /test1/ 200
[Tue, 10 Aug 2010 21:47:36 GMT] [debug] [<0.7379.0>] 'GET' /test1/_local%2F1f98502a8cbe6323ed57f51e919cc602 {1,0}
Headers: [{'Accept',"application/json"},
{'Accept-Encoding',"gzip"},
{'Authorization',"Basic am9jaGVuOmphd29zaXM5"},
{'Connection',"close"},
{'Host',"204.232.210.206:5984"},
{'User-Agent',"CouchDB/0.11.1"},
{'X-Forwarded-For',"201.215.36.77"},
{"X-Real-Ip","201.215.36.77"}]
[Tue, 10 Aug 2010 21:47:36 GMT] [debug] [<0.7379.0>] Minor error in HTTP request: {not_found,missing}
[Tue, 10 Aug 2010 21:47:36 GMT] [debug] [<0.7379.0>] Stacktrace: [{couch_httpd_db,couch_doc_open,4},
{couch_httpd_db,db_doc_req,3},
{couch_httpd_db,do_db_req,2},
{couch_httpd,handle_request_int,5},
{mochiweb_http,headers,5},
{proc_lib,init_p_do_apply,3}]
[Tue, 10 Aug 2010 21:47:36 GMT] [info] [<0.7379.0>] 201.215.36.77 - - 'GET' /test1/_local%2F1f98502a8cbe6323ed57f51e919cc602 404
[Tue, 10 Aug 2010 21:47:36 GMT] [debug] [<0.7379.0>] httpd 404 error response:
{"error":"not_found","reason":"missing"}
[Tue, 10 Aug 2010 21:47:38 GMT] [debug] [<0.7382.0>] 'GET' /test1/_changes?style=all_docs&heartbeat=10000&since=0&feed=normal {1,0}
Headers: [{'Accept',"application/json"},
{'Authorization',"Basic am9jaGVuOmphd29zaXM5"},
{'Connection',"close"},
{'Host',"204.232.210.206:5984"},
{'User-Agent',"CouchDB/0.11.1"},
{'X-Forwarded-For',"201.215.36.77"},
{"X-Real-Ip","201.215.36.77"}]
[Tue, 10 Aug 2010 21:47:38 GMT] [info] [<0.7382.0>] 201.215.36.77 - - 'GET' /test1/_changes?style=all_docs&heartbeat=10000&since=0&feed=normal 200
[Tue, 10 Aug 2010 21:47:40 GMT] [debug] [<0.7385.0>] 'GET' /test1/_design%2FTest?open_revs=["1-0216605ef384362605fb46b1a6310ad3"]&revs=true&latest=true&att_encoding_info=true {1,
0}
Headers: [{'Accept',"application/json"},
{'Accept-Encoding',"gzip"},
{'Authorization',"Basic am9jaGVuOmphd29zaXM5"},
{'Connection',"close"},
{'Host',"204.232.210.206:5984"},
{'User-Agent',"CouchDB/0.11.1"},
{'X-Forwarded-For',"201.215.36.77"},
{"X-Real-Ip","201.215.36.77"}]
[Tue, 10 Aug 2010 21:47:40 GMT] [info] [<0.7385.0>] 201.215.36.77 - - 'GET' /test1/_design%2FTest?open_revs=["1-0216605ef384362605fb46b1a6310ad3"]&revs=true&latest=true&att_encoding_info=true 301
[Tue, 10 Aug 2010 21:47:41 GMT] [debug] [<0.7389.0>] 'GET' /test1/_design%2Ftest?open_revs=["5-89567776bc3a8780d34fd5112a1dfbd1"]&revs=true&latest=true&att_encoding_info=true {1,
0}
Headers: [{'Accept',"application/json"},
{'Accept-Encoding',"gzip"},
{'Authorization',"Basic am9jaGVuOmphd29zaXM5"},
{'Connection',"close"},
{'Host',"204.232.210.206:5984"},
{'User-Agent',"CouchDB/0.11.1"},
{'X-Forwarded-For',"201.215.36.77"},
{"X-Real-Ip","201.215.36.77"}]
[Tue, 10 Aug 2010 21:47:41 GMT] [info] [<0.7389.0>] 201.215.36.77 - - 'GET' /test1/_design%2Ftest?open_revs=["5-89567776bc3a8780d34fd5112a1dfbd1"]&revs=true&latest=true&att_encoding_info=true 301
[Tue, 10 Aug 2010 21:56:43 GMT] [debug] [<0.7893.0>] 'PUT' /test1/_design/test {1,0}
Headers: [{'Accept',"*/*"},
{'Authorization',"Basic am9jaGVuOmphd29zaXM5"},
{'Connection',"close"},
{'Content-Length',"101"},
{'Content-Type',"application/x-www-form-urlencoded"},
{'Host',"204.232.210.206:5984"},
{'User-Agent',"curl/7.19.7 (i486-pc-linux-gnu) libcurl/7.19.7 OpenSSL/0.9.8k zlib/1.2.3.3 libidn/1.15"},
{'X-Forwarded-For',"201.215.36.77"},
{"X-Real-Ip","201.215.36.77"}]
[Tue, 10 Aug 2010 21:56:43 GMT] [info] [<0.7893.0>] 201.215.36.77 - - 'PUT' /test1/_design/test 201
{"error":"json_encode","reason":"{bad_term,{nocatch,{invalid_json,<<\"<html>\\r\\n<head><title>401 Authorization Required</title></head>\\r\\n<body bgcolor=\\\"white\\\">\\r\\n<center><h1>401 Authorization Required</h1></center>\\r\\n<hr><center>nginx/0.7.65</center>\\r\\n</body>\\r\\n</html>\\r\\n\">>}}}"}
Chain INPUT (policy ACCEPT)
target prot opt source destination
ACCEPT tcp -- anywhere anywhere state NEW,ESTABLISHED tcp dpt:https
ACCEPT all -- anywhere anywhere
ACCEPT all -- anywhere anywhere state RELATED,ESTABLISHED
ACCEPT tcp -- anywhere anywhere tcp dpt:ssh
ACCEPT tcp -- anywhere anywhere tcp dpt:www
ACCEPT tcp -- anywhere anywhere tcp dpt:5984
Chain FORWARD (policy ACCEPT)
target prot opt source destination
Chain OUTPUT (policy ACCEPT)
target prot opt source destination
user www-data;
worker_processes 4;
error_log /var/log/nginx/error.log;
pid /var/run/nginx.pid;
events {
worker_connections 8192;
use epoll;
# multi_accept on;
}
http {
include /etc/nginx/mime.types;
access_log /var/log/nginx/access.log;
sendfile on;
#tcp_nopush on;
#keepalive_timeout 0;
keepalive_timeout 70;
tcp_nodelay on;
gzip on;
gzip_disable "MSIE [1-6]\.(?!.*SV1)";
include /etc/nginx/conf.d/*.conf;
include /etc/nginx/sites-enabled/*;
server {
listen 204.232.210.206:5984;
server_name 204.232.210.206;
client_max_body_size 10m;
location / {
auth_basic "Privado";
auth_basic_user_file /etc/sites/htpasswd/rrhhchile.cl;
set $authorization upstream_http_authorization;
proxy_pass http://localhost:5984;
proxy_redirect off;
proxy_buffering off;
proxy_set_header Host $host:$proxy_port;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
location ~ ^/(.*)/_changes {
auth_basic "Privado";
auth_basic_user_file /etc/sites/htpasswd/rrhhchile.cl;
proxy_pass http://localhost:5984;
proxy_redirect off;
proxy_buffering off;
proxy_set_header Host $host:$proxy_port;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment