Thanks so much for helping us to get owncloud setup. I followed Joshua's original post, along with cyberjocks' SSL post and Rickie's fail2ban post and everything is working really well!
That being said, I just started running into issues the second I tried to open my owncloud to the outside world. I have my router forwarding inbound port 60000 to the IP of my owncloud on private port 443. My freenas has a no-ip host registered which works fine (configured SSH to my freenas host). When I'm within my LAN, I type in
https://my-no-ip.ddns.net:60000/owncloud
but I get "Unable to connect" and the address bar becomes "https://my-no-ip.ddns.net/owncloud/". If i insert ":60000" back in there after the ".net", then i am able to get to my owncloud instance. Outside of my LAN, typing "https://my-no-ip.ddns.net:60000/owncloud" prompts the browser to accept the SSL certificate but after it's accepted, the page just hangs. I'm pretty sure it's something with my nginx setup and was hoping someone could take a look and give me some pointers. Thanks in advance!
That being said, I just started running into issues the second I tried to open my owncloud to the outside world. I have my router forwarding inbound port 60000 to the IP of my owncloud on private port 443. My freenas has a no-ip host registered which works fine (configured SSH to my freenas host). When I'm within my LAN, I type in
https://my-no-ip.ddns.net:60000/owncloud
but I get "Unable to connect" and the address bar becomes "https://my-no-ip.ddns.net/owncloud/". If i insert ":60000" back in there after the ".net", then i am able to get to my owncloud instance. Outside of my LAN, typing "https://my-no-ip.ddns.net:60000/owncloud" prompts the browser to accept the SSL certificate but after it's accepted, the page just hangs. I'm pretty sure it's something with my nginx setup and was hoping someone could take a look and give me some pointers. Thanks in advance!
Code:
#user nobody; worker_processes 3; #error_log logs/error.log; #error_log logs/error.log notice; #error_log logs/error.log info; #pid logs/nginx.pid; events { worker_connections 1024; } http { include mime.types; default_type application/octet-stream; #log_format main '$remote_addr - $remote_user [$time_local] "$request" ' # '$status $body_bytes_sent "$http_referer" ' # '"$http_user_agent" "$http_x_forwarded_for"'; #access_log logs/access.log main; sendfile on; tcp_nopush on; #keepalive_timeout 0; keepalive_timeout 65; gzip off; gzip_vary on; gzip_proxied any; gzip_comp_level 9; gzip_http_version 1.1; gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/java$ ssl_certificate /usr/local/etc/nginx/server.crt; ssl_certificate_key /usr/local/etc/nginx/server.key; server { listen 80; listen 443 ssl; root /usr/local/www; location = /robots.txt { allow all; access_log off; log_not_found off; } location = /favicon.ico { access_log off; log_not_found off; } location ^~ /owncloud { index index.php; try_files $uri $uri/ /owncloud/index.php$is_args$args; client_max_body_size 512M; location ~^/owncloud/(?:\.|data|config|db_structure\.xml|README) { deny all; } location ~ \.php(?:$|/) { fastcgi_split_path_info ^(.+\.php)(/.*)$; fastcgi_pass unix:/var/run/php-fpm.sock; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param PATH_INFO $fastcgi_path_info; include fastcgi_params; fastcgi_param MOD_X_ACCEL_REDIRECT_ENABLED on; } location ~* \.(?:jpg|gif|ico|png|css|js|svg)$ { expires 30d; add_header Cache-Control public; } location ^~ /owncloud/data { internal; alias /mnt/files; } } } }