I have a usual 'working' nginx file which works fine when being tested. The /etc/nginx/nginx.conf file
user www-data; worker_processes auto; pid /run/nginx.pid; include /etc/nginx/modules-enabled/*.conf; events { worker_connections 768; # multi_accept on; } http { ## # Basic Settings ## sendfile on; tcp_nopush on; tcp_nodelay on; tcp_nodelay on; keepalive_timeout 65; types_hash_max_size 2048; # server_tokens off; # server_names_hash_bucket_size 64; # server_name_in_redirect off; include /etc/nginx/mime.types; default_type application/octet-stream; ## # SSL Settings ## ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # Dropping SSLv3, ref: POODLE ssl_prefer_server_ciphers on; ## # Logging Settings ## access_log /var/log/nginx/access.log; error_log /var/log/nginx/error.log; ## # Gzip Settings ## gzip on; include /etc/nginx/conf.d/*.conf; include /etc/nginx/sites-enabled/*; } But when edited with the server details below, I get this error nginx: [emerg] "server" directive is not allowed here in /etc/nginx/nginx.conf:90 nginx: configuration file /etc/nginx/nginx.conf test failed. How do I overcome this?? server { listen 443; server_name server_domain_or_IP; root html; index index.html index.htm; ssl on; ssl_certificate /etc/nginx/ssl/myapp.crt; ssl_certificate_key /etc/nginx/ssl/myapp.key; ssl_session_timeout 5m; #ssl_protocols SSLv3 TLSv1 TLSv1.1 TLSv1.2; ssl_protocols TLSv1 TLSv1.1 TLSv1.2; ssl_ciphers "HIGH:!aNULL:!MD5 or HIGH:!aNULL:!MD5:!3DES"; ssl_prefer_server_ciphers on; location / { include uwsgi_params; uwsgi_pass unix:/home/user/myapp/myapp.sock; } } -- Resources: - http://web2py.com - http://web2py.com/book (Documentation) - http://github.com/web2py/web2py (Source code) - https://code.google.com/p/web2py/issues/list (Report Issues) --- You received this message because you are subscribed to the Google Groups "web2py-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to web2py+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/81fa64da-c6e1-4237-a154-56f064443d82%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.