farmOS-legacy / farmOS.org

This is the code that runs the official v1.farmOS.org website.
http://v1.farmos.org
47 stars 72 forks source link

Configuring a Local Https Reverse Proxy on Windows #83

Closed and712 closed 4 years ago

and712 commented 4 years ago

Hello together, as you probably have seen in the riot chat i had some problems with my farmOS running on an nginx server. So i looked a bit deeper into the reverse proxy guide and tried to setup it up on my Windows 10 machine and after some try and error i was successful.

One problem i can into with the docker file:

Problem: Mounting files on windows

docker-compose.yml

volumes:
      - './nginx.conf:/etc/nginx/nginx.conf'
      - './nginx/error_logs:/etc/nginx/error_logs'
      - './devcerts:/etc/nginx/certs'

It seems like its not possible to mount files in windows (as described here: https://stackoverflow.com/questions/58864411/cant-mount-file-on-windows-container - i couldn't find a source for that from docker)

Solution:

docker-compose.yml

volumes:
      - './nginx:/etc/nginx/'

i moved all files in one dir to solve that issue. The new structure looks like this:

nginx/ 
--| nginx.conf 
--| error_logs/
--| certs/
       --| cert.pem
       --| key.pem

Conclusion:

Is there any demand for an full windows guide? Then i could try to provide one

mstenta commented 4 years ago

If you have the time and interest, it would be great to have a Windows guide too! If not on farmOS.org, then it could even just be a post on the forum! https://farmOS.discourse.group

We talked on a recent monthly call about this idea of "time-dated" tutorials/guides/etc, and how to enable more community-generated resources like that... but also the need to balance maintaining/updating pages that are on farmOS.org (the "official" guide). We sort of landed on: let's just encourage those kinds of guides to be written in either a "blog" on farmOS.org or on the forum - and the expectation is: "here is an article written at a specific point in time. it may still be relevant, but it is not being updated". That idea really frees up the ongoing maintenance of the site, but also allows for these guides to exist!

We are talking about upgrading the website to Gatsby.js in the future, at which point we may add a blog section. But for now, the forum would be a great place to sketch this up. And then in the future maybe we can pull it into a blog post!

Thanks @and712 for contributing!

and712 commented 4 years ago

after more tests with docker on windows, i would not recommend to add a windows section in farmOS.org, because there are more issues then the above one. (e.g. some containers are not running in windows, like postgres) and differences in docker-compose. i would recommend to add an advice to setup a linux vm in the docs and not use docker on windows.

what do you think about that?

mstenta commented 4 years ago

@and712 Yea more and more I am thinking about the separation between "official docs" and "community articles/guides" that are written by members of the community, but are not maintained/updated by farmOS maintainers.

As far as "official support" - I don't have any interest myself in officially saying that "farmOS supports Windows hosting". It may work fine, but as soon as we say "it's official" then we are obligated to make sure it works, etc etc. I am much more inclined to say "we officially support this Docker container, which includes all the dependencies. we ensure that it runs on linux, and it probably runs on other systems but that's up to you to figure out. here is a link to some community guides" or something like that.

mstenta commented 4 years ago

If it's alright with you, we can close this issue. If anyone in the future wants to write a Windows guide, they can. Perhaps by then we'll have the "blog" feature set up on farmOS.org to accommodate community contributed guides. Or, at the very least, folks can write on other sites and we can make a page that links to them.