brysontyrrell / PatchServer

A self-hosted implementation of an external patch source for Jamf Pro 10.2+
http://patchserver.readthedocs.io/en/latest/
MIT License
67 stars 13 forks source link

Let's Encrypt setup? #35

Open dmarcsift opened 3 years ago

dmarcsift commented 3 years ago

Somewhat a noob when it comes to Docker but successfully spun up PatchServer in a Docker container on a server. Wondering how I can get SSL enabled on it using Let's Encrypt? I'm sure someone has done this before, and I know how to get LE on a regular VM/bare metal server. I've never done it with a container before. Any help would be appreciated.

mattMali commented 3 years ago

a. https://certbot.eff.org/instructions b. https://medium.com/@pentacent/nginx-and-lets-encrypt-with-docker-in-less-than-5-minutes-b4b8a60d3a71 c. https://github.com/brysontyrrell/PatchServer/blob/develop/docs/setup/docker.md#enable-proxy-support

PatchServer (run.py) doesn't have built-in SSL/HTTPS certificate binding/functionality, although it does support the use of an HTTP proxy/forwarder...Nginx/Apache/etc can be used to redirect/forward the non-SSL traffic from PatchServer, for example:

--> PatchServer HTTP port == tcp,5000 --> Nginx HTTPS/SSL port == tcp,5443 --> Docker/Container/Host == host.domain --> Jamf/patchServer+SSL == https://host.domain:5443/jamf/v1

brysontyrrell commented 3 years ago

@mattMali would you like to submit a PR for the documentation about basic LetsEncrypt setup?