Welcome! Log In Create A New Profile


Use proxy_pass to forward traffic to owncloud server

January 19, 2017 01:29AM
Hello All,

I have 2 Raspberry Pi both with nginx.
RPI#1 is plain website (using http) (listening on port 8000) (local IP : 1.2.1-2.2 )
RPI#2 is an owncloud server (using https) (local IP

My dyndns domain name gets routed to RPI#1.
nginx on RPI#1 uses following server & proxy_pass stanza:

server {
listen 8000; ## listen for ipv4; this line is default and implied
listen 80;
listen 443;
#listen [::]:80 default_server ipv6only=on; ## listen for ipv6

root /media/usbstick/nginx/www;
index index.php index.html index.htm;

# Make site accessible from http://localhost/
server_name rpi1;

... other location stanzas ...

location /owncloud {

If I put a minimum http config file on RPI#2 it works.
upstream php-handler {
server {
listen 80;
root /media/usbstick/nginx/www/owncloud;
server_name rpi3;
location / {
try_files $uri $uri/ /index.html;
ssi on;

With following index.html file.

<title>Under Construction</title>
<p>This page is under construction. Please come back soon!</p>

When entering I get the 'under construction' message.
That is confirmed from local LAN or from WAN when using my dyndns domain.

When I'm using the nginx config provided by owncloud tutorial:

This one puts all traffic on https.
upstream php-handler {
#server unix:/var/run/php5-fpm.sock;

server {
listen 80;
server_name xxxxxxx.dyndns.ws;
return 301 https://$server_name$request_uri; # enforce https

server {
listen 443 ssl;
server_name xxxxxxx.dyndns.ws;
add_header Strict-Transport-Security "max-age=31536000; includeSubDomains";
... more stuff ...

I get this error (firefox).
An error occurred during a connection to xxxxxx.dyndns.ws. SSL received a record that exceeded the maximum permissible length. (Error code: ssl_error_rx_record_too_long)

What's the proper setup of getting the https traffic to work?

Subject Author Posted

Use proxy_pass to forward traffic to owncloud server

forumacct January 19, 2017 01:29AM

Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 53
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready