[Support] knex666 - Nextcloud 21


knex666

Recommended Posts

On 4/8/2020 at 11:24 AM, Abigel said:

Hi,

okay but how can i change the access to the nextcloud via https 443 and not port 80 ?

My mapping is now set with -p '445:443/tcp' -p '8080:80'

But i can only access with the 8080 and if i have only 443 with 445 it doesnt work.

I want only a secure access over https.

After editing the ports:

When I right-click the WebUI, it just opens the GUI of Unraid because it is accessed via port 80

Please read the First post. Therefore you need a let's encrypt docker. Nextcloud has no ssl configuration. 

Link to comment
9 hours ago, Abigel said:

But I can use nextcloud from linuxserver in home network over https

Why is it not possible with this container?

Because its not LSIO and I did not change any configuration. 

 

You habe two options to get this done

1. Use a reverse proxy with self signed certificate 

2. Did not test this but you can Mount your self aigned certificates and your mounted edited apache config. 

 

I prefer Option 1

 

Cheers

  • Like 2
Link to comment
6 hours ago, knex666 said:

just use docker exec

I mean the occ nextcloud commands. Where is the path to the occ ?

Another question:

my onlyoffice is not working because i don't know what to do 😕

In the local network it works fine but over dynamic-dns not.

Should I set the onlyoffice-settings to: "https://nextcloud.mydomain.com/apps/documentserver_community/"

or "http://192.168.5.5/apps/documentserver_community/"

and should i change something else?

And

If i want to connect my windows-Desktop-Client this error is shown: "

400 Bad Request

The plain HTTP request was sent to HTTPS port

nginx/1.16.1"

Edited by Abigel
Link to comment

After over 12 hours of attempted migration from LISIO to this container I give up.
I had managed to migrate the most necessary database entries manually from the old database to the new one, migrating the users, the files, apps and settings. I have changed the letsencrypt-Docker-Settings. Now the http over port 80 falls on my feet...
No client, no matter if Android or Windows can connect, after the browser redirection nothing happens or the above mentioned error message. OnlyOffice works only in the local network.

I would be very grateful if you could write a 1 to 1 guide for a migration from linuxserver.io to this container. Then I would like to try it again

Link to comment
2 hours ago, Abigel said:

I mean the occ nextcloud commands. Where is the path to the occ ?

docker exec -u www-data nextcloud /var/www/html/occ  ;-)

Quote

Another question:

my onlyoffice is not working because i don't know what to do 😕

In the local network it works fine but over dynamic-dns not.

Should I set the onlyoffice-settings to: "https://nextcloud.mydomain.com/apps/documentserver_community/"

or "http://192.168.5.5/apps/documentserver_community/"

and should i change something else?

And

If i want to connect my windows-Desktop-Client this error is shown: "

400 Bad Request

The plain HTTP request was sent to HTTPS port

nginx/1.16.1"

Thats totally my problem too and I did not found a solution.

You can choose between one of those addr. Maybe a question for the nextcloud community.

Since I can edit my stuff in my local network with the office suite I stoped going for a research. please feel free to do so!

Edited by knex666
Link to comment
1 hour ago, Abigel said:

After over 12 hours of attempted migration from LISIO to this container I give up.
I had managed to migrate the most necessary database entries manually from the old database to the new one, migrating the users, the files, apps and settings. I have changed the letsencrypt-Docker-Settings. Now the http over port 80 falls on my feet...
No client, no matter if Android or Windows can connect, after the browser redirection nothing happens or the above mentioned error message. OnlyOffice works only in the local network.

I would be very grateful if you could write a 1 to 1 guide for a migration from linuxserver.io to this container. Then I would like to try it again

After 95% you gave up?

You can only get access with http - solutions with internal an external reverse proxy are given in a lot of posts for unraid.

Only office only works on one network from outside or from inside - see the post above this, there is no solution jet.

Link to comment
20 hours ago, knex666 said:

After 95% you gave up?

You can only get access with http - solutions with internal an external reverse proxy are given in a lot of posts for unraid.

Only office only works on one network from outside or from inside - see the post above this, there is no solution jet.

I don't know what to do to solve the problem with the client connection.

 

What should I do to use only office only from outside ?

 

 

My let's encrypt container nginx config:

server {

listen 80 default_server; server_name _; 
return 301 https://$host$request_uri; 
} 
upstream backend { 
					server 192.168.5.5:19999; 
					keepalive 64; }

#####Nextcloud 
server { 
	listen 443 ssl; 
	server_name nextcloud.mydomain.com; 
	root /config/www; index index.html index.htm index.php;

###SSL Certificates 
ssl_certificate /config/keys/letsencrypt/fullchain.pem; 
ssl_certificate_key /config/keys/letsencrypt/privkey.pem;

###Diffie–Hellman key exchange ### 
ssl_dhparam /config/nginx/dhparams.pem; 

###SSL Ciphers ssl_ciphers 'xxx-RSA-AES128-SHA256:ECDHE-xxx-AES$

###Extra Settings### 
ssl_prefer_server_ciphers on; 
# ssl_session_cache shared:SSL:10m;

### Add HTTP Strict Transport Security 
### add_header Strict-Transport-Security "max-age=63072000; includeSubdomains"; 
##  add_header Front-End-Https on; client_max_body_size 0;

### now nextcloud config
location / { 
proxy_pass http://192.168.5.5:8080/; 
proxy_max_temp_file_size 2048m; 
include /config/nginx/proxy.conf; } }

 

Edited by Abigel
Beauty of the Config
Link to comment
15 hours ago, Abigel said:

I mean the occ nextcloud commands. Where is the path to the occ ?

Another question:

my onlyoffice is not working because i don't know what to do 😕

In the local network it works fine but over dynamic-dns not.

Should I set the onlyoffice-settings to: "https://nextcloud.mydomain.com/apps/documentserver_community/"

or "http://192.168.5.5/apps/documentserver_community/"

and should i change something else?

And

If i want to connect my windows-Desktop-Client this error is shown: "

400 Bad Request

The plain HTTP request was sent to HTTPS port

nginx/1.16.1"

Here is an answere from the nextcloud community. very complex but doable:

 

https://help.nextcloud.com/t/open-onlyoffice-from-internal-and-external-network-not-possible/77861

 

Link to comment
7 hours ago, Abigel said:

Thanks

The Only Office topic is secondary for me.

First of all nextcloud should run with the clients, don't know how

This is my "outside" conf - works well.

Please note that this is not a LetsEncrypt config. You will find a lot of examples for LetsEncrypt.

 

server {
	listen 443 ssl;
	listen [::]:443 ssl; 
	
	server_name cloud.mydomain.com;

	root /var/www/html;

	server_tokens off;
	ssl_certificate /etc/letsencrypt/live/cloud.mydomain.com/fullchain.pem; # managed by Certbot
	ssl_certificate_key /etc/letsencrypt/live/cloud.mydomain.com/privkey.pem; # managed by Certbot
	ssl_ciphers '*******!KRB5-DES-CBC3-SHA';
	ssl_prefer_server_ciphers on;       
	add_header Strict-Transport-Security max-age=15768000;


location /{
        proxy_pass http://[1a01:123:4c1:f260::35b]/;
	proxy_http_version 1.1;
	proxy_redirect off;
        proxy_set_header Host $host;
        proxy_set_header X-Real-IP $remote_addr;#proxy_set_header Host $host;
        proxy_set_header   X-Forwarded-For  $proxy_add_x_forwarded_for;
        proxy_set_header X-Forwarded-Proto $scheme;

    }


}

server {
    if ($host = cloud.mydomain.com) {
        return 301 https://$host$request_uri;
    } # managed by Certbot


	listen 80;
	listen  [::]:80; 
	
	server_name cloud.mydomain.com;
    return 404; # managed by Certbot
}

 

Edited by knex666
Link to comment
4 hours ago, knex666 said:

This is my "outside" conf - works well.

Please note that this is not a LetsEncrypt config. You will find a lot of examples for LetsEncrypt.

 


	ssl_ciphers 'ECXXX-DES-CBC3-SHA';
	

 

Thank you very much for your Config!
I don't know if it is important but maybe you should delete or falsify your shiffre code ?

I had letsencrypt running with my above mentioned config and the old nextcloud container, so it should work with this container, I only change the IP address, so can the problem be somewhere else ? I can access the Nextcloud via Web but not via the clients

Can you please also show all your nextcloud config.php?

 

I get to the point where I want to connect to the windows client, I type in the URL, click on continue, browser opens for verification, I press allow access and then nothing happens, the wheel turns and nothing more. At the client the message comes then:
"Error accessing the 'token' endpoint:
Error transferring http://mydomain.de:443/login/v2/poll - server replied: Bad Request


I really don't know any more

 

Edited by Abigel
Link to comment
1 hour ago, Abigel said:

Thank you very much for your Config!
I don't know if it is important but maybe you should delete or falsify your shiffre code ?

I had letsencrypt running with my above mentioned config and the old nextcloud container, so it should work with this container, I only change the IP address, so can the problem be somewhere else ? I can access the Nextcloud via Web but not via the clients

Can you please also show all your nextcloud config.php?

 

I get to the point where I want to connect to the windows client, I type in the URL, click on continue, browser opens for verification, I press allow access and then nothing happens, the wheel turns and nothing more. At the client the message comes then:
"Error accessing the 'token' endpoint:
Error transferring http://mydomain.de:443/login/v2/poll - server replied: Bad Request


I really don't know any more

 

Hi,

 

could you please delete thy chiper from your quotation? ;-)

 

I think its because there is no http/s rewrite. It trys to connect to HTTP://...:443 that never would work anyway.

 

Cheers

  • Thanks 1
Link to comment

Of course, i have delete it, sry

 

And now i have the solution for the rewrite problem :)

After debugging with firefox when i push the button for confirmation, it says that something is blocked from the request.

I have add " 'overwriteprotocol' => 'https'," into the config.php and now the client can connect!

Thanks for your patience and help!

Now I sit down at the OnlyOffice problem

 

@knex666 can you please show your config.php from nextcloud?

Edited by Abigel
Link to comment
21 hours ago, Abigel said:

Of course, i have delete it, sry

 

And now i have the solution for the rewrite problem :)

After debugging with firefox when i push the button for confirmation, it says that something is blocked from the request.

I have add " 'overwriteprotocol' => 'https'," into the config.php and now the client can connect!

Thanks for your patience and help!

Now I sit down at the OnlyOffice problem

 

@knex666 can you please show your config.php from nextcloud?

Fine, that solution and eventhough the solution about OnlyOffice is written down at the forst post of this Thread ;-)

Link to comment
4 hours ago, Abigel said:

I can't find the file

I have searched it manually and with find -iname

no results

/usr/local/etc/php/

 

but since you search for the error with the max upload size - search at your reverse proxy. Nextcloud is setup fine to get large files. If you are running LetsEncrypt edit the nginx config ;-)

 

Cheers

Edited by knex666
Link to comment

 

13 hours ago, knex666 said:

/usr/local/etc/php/

 

but since you search for the error with the max upload size - search at your reverse proxy. Nextcloud is setup fine to get large files. If you are running LetsEncrypt edit the nginx config ;-)

 

Cheers

I had the same proxy settings on the other container and the message did not come up. I have now increased all possible values in nginx and nextcloud but it still does not work.

I can upload files that are larger than 5GB but i can't set a background image that is 5MB

Edited by Abigel
Link to comment
  • knex666 changed the title to [Support] knex666 - Nextcloud 21

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.