Hey,
I got it running a few minutes ago, Iām just double checking and uploading the hopefully working configuration. Stay tuned
Hey,
I got it running a few minutes ago, Iām just double checking and uploading the hopefully working configuration. Stay tuned
Hey,
I finally got a working version again. Seems that keeping old configuration files can trick you very badly ;).
Steps to repoduce:
Be sure to cd
to your docker-compose folder
Cancel running docker-containers
docker-compose down
docker-compose.yml
and ./nextcloud and ./proxy directories). Everything will be recreated automatically.rm ./* -r
curl https://gist.githubusercontent.com/SnowMB/758bb6c993372111629f4e86c0e1de1a/raw/b1e6d4454ef4af302eca19061bebbd573725d96f/docker-compose.yml > docker-compose.yml
nano docker-compose.yml
mkdir proxy/templates -p
curl https://gist.githubusercontent.com/SnowMB/87c5360f9bf81925af26c31f6d71410e/raw/fc8784d1cbc8ad56047b10630b68c1830859bf63/nginx.tmpl > ./proxy/templates/nginx.tmpl
docker-compose up -d
When you can confirm that it works Iāll rework the guide in the first post.
Hey mate, you are an absolute legend!!
Hugely appreciate your time and efforts helping me with this!
I am just away from my Mac atm but will definitely try this out either tonight or tomorrow and report back.
Have a great weekend!
Hello
Had the same issue than tk1, and werenāt able to find why it wasnāt working.
Just retry with your last docker-compose.yml and nginx.tmpl and I can confirm itās working on my side.
Thanks
Another weird behavior, I canāt upload file more than 1M.
Itās well configured in nextcloud to 10G, but seems that nginx variable client_max_body_size is not set, so we use the default 1M value.
Do you have the same problem ?
Hi Snowyo
Sincere apologies for the delay in getting back to youā¦had something come up at work and wasnāt able to get back to this.
Okay the good news is that I have managed to get it working following your latest instructions!!
The only issue I am currently experiencing is (as per tinsjourney above) I cannot seem to upload any files above 4M in size (in fact it might even be less than this but thats just were the desktop client seems to reset).
Steps I have taken to fix this:
Adding the following to ./proxy/conf.d/default.conf
http {
client_max_body_size 30M;
}
I then restarted the nginx container.
This did not fix the problem. Any ideas?
Did you find any solution to this as yet?
I have not found a fix for the configuration above. But with digging into the topic I tried out this container image by the same author that combines the docker-gen and nginx reverse proxy function in one container and seems to be more user friendly.
The docker-compose file is very similar to the other configuration:
With this configuration there is an easy fix for your problem:
Create a .conf file and add it to the folder ./proxy/conf.d/
. The name does not matter.
client_max_body_size 100m;
(You just need this one line)
For more information see GitHub - nginx-proxy/nginx-proxy: Automated nginx proxy for Docker containers using docker-gen
No luck unfortunately
Tried adding this line to the default.conf file which gets created after running the docker-compose (tried pausing and unpausing etc.) and also tried adding in a separate file.conf to ./proxy/conf.d/
but again, no luck.
Any thoughts?
PS - still not had any further success integrating the wekan container into this setup. My ultimate goal is to be able to integrate wekan and possibly one or two other images (Wordpress etc.) as well. Any help (as always) would be hugely appreciated!
Have a great weekend.
Hmm,
For your Wekan container problem you can try this:
There might be an issue with the docker networks. Docker-compose version 2 creates a network for each docker compose file. So when you start the wekan container with a seperate compose file it might not be recognised.
Solution to this is creating a external docker-network like I explained in the initial post. You have to add the nginx proxy, wonderfall/nextcloud and mariadb container to the network. When creating the compose file for your wekan container define the same external network and add the wekan container to it.
Sorry I am a little confusedā¦ Do I create a new docker-network (named something else) so that I end up with two networks? And if so, which containers connect to which network(s)?
If you have the time I would be very grateful for a step-by-step walk through of the process to get this up and running successfully. Once I have learnt how to do this I am hopeful I will be able to replicate the procedure to do the same with a WordPress container!
Appreciate your help very much my friend!
Ok Sorry for the confusion
It depends a little on where you started. If you started with my original guide from the first post you have created a docker network in the past and can use that one. The solution I posted later didnāt use an external network.
What I got from reading the guides for the containers and Issues on GitHub is the following:
So the step by step solution would be the following:
docker network ls
. Look for something like that3202169f7225 nginx-proxy bridge local
docker network create -d bridge nginx-proxy
networks:
ā¦proxy-tier:
ā¦external:
ā¦name: nginx-proxy
networks:
ā¦- proxy-tier
Cheers mate, Iāll try this now!
BTW - I found this yesterday -->
http://steveltn.me/2015/12/18/nginx-acme/
Seems to simplify things greatly. Apparently not compatible with v2 docker-compose but wondering does this matter?
Have written to the author for some guidance on integration with other containers but not heard back as yet. Will keep you posted if/when I hear anything.
Thanks again my friend!
Hey,
Could be a possibility, but as far as I see it has one downside: It requires you to list all domains in the https-portal compose file. Your setup with 2 seperate compose files or dynamically adding containers for other sub domains seems impossible without reconfiguring and restarting https-portal.
There is a somewhat simpler solution than the 3 containers (nginx, docker-gen, letsencrypt) that I postet before. It uses the same tech, but combines nginx and docker-gen in one container. With that setup the template file is included in the container, so you donāt have to worry about that anymore. It is heavily used (>5million pulls from dockerhub) and developed (currently > 30 pull requests on github).
When going through the comits to the template file in the container, I saw that there are some security issues adressed, that I would not have ever known of. So I feel better off having the community keeping track of it
In my test the letsencrypt integration worked without any problems and personally Iāll go with this container from now on. When I have some free time Iāll rewrite the whole guide and give some new docker-compose examples.
Hey,
Thank you Snowoy for the great work. I have now repeated your instructions couple of times but all the times I get to the same error. I get the service up and running quite stably, but when I fill the login credentials for the db I get following error message
Error while trying to create admin user: Failed to connect to the database: An exception occured in driver: SQLSTATE[HY000] [2002] Can't connect to local MySQL server through socket '/run/mysqld/mysqld.sock' (2 "No such file or directory")
Just canāt figure out what this is aboutā¦
thanks for this info.
I confirm it works when adding the line to ./proxy/conf.d
FYI I also try a per virtual host conf described here https://github.com/jwilder/nginx-proxy#per-virtual_host
but it doesnāt work when you first start your container and wait for letās encrypt request on port 80.
Once you have a valid certificate, and you had your custom nginx con to ./proxy/vhost.d/{VIRTUAL_HOST}
thereās no problem.
need to check with JrCs/docker-letsencrypt-nginx-proxy-companion
@yatzy can you post the docker compose logs?
docker-compose logs
Possible solutions I can think of right know:
volumes:
- ./nextcloud/db:/var/lib/mysql
docker-compose down
sudo rm nextcloud/db/ -r
docker-compose up -d
@tinsjourney thanks for the info
Heres the docker-compose logs
pastebin
Could not find anything unusual from db container. Worth of noting that Iām somewhat new to docker, but I guess ādocker inspect mariadb:10ā was what you were looking for?
After restarting the containers could not connect to nextcloud anymore.
Thank you for your help! It would be brilliant to get this working.
I meant the volume definition in the compose file.
I compared your log with the logs of my working setup and found no unusual lines or errors. Could you show the compose file? (remember to replace/delete passwords / domain name before uploading)
hey snowyo
iāve been messing around with owncloud for years, never got it working ā¦
now nextcloudās guideline are a little more user friendly, I got it working but when I try to configure the fancy performance enhancing thingies like php-fpm and memchache, my knowlege results in a broken dedicated ubuntu server wich i need to reinstallā¦ also reverse dns a lot of trial and error
so now i want to figure things out with docker
do you have any tips or guides? github sents me to : https://github.com/indiehosters/nextcloud
thx anyway