Securing N8N on Primary Domain at Port 5678 with SSL

I’m attempting to secure my N8N instance running on Docker from my primary domain using Let’s Encrypt on CentOS with CyberPanel. HTTP works fine, but HTTPS fails to function.

I experienced a similar issue when trying to secure my Docker-hosted n8n instance. The problem was not with Let’s Encrypt itself, but rather with the way the reverse proxy was handling the traffic. My setup involved Nginx as the frontend, and I had to ensure the SSL termination was done correctly before the requests were forwarded to the n8n container. I spent some time reviewing the configuration, and it turned out that the HTTPS port was misconfigured. Once I adjusted the proxy and double checked the certificate paths, things started working as expected. I recommend verifying each component along your chain.

The issue might be related to how traffic is routed from the primary domain to the Docker container rather than solely with Let’s Encrypt. I faced a similar challenge and discovered that even with a valid certificate, improper port mapping and firewall settings disrupted the secure connection. Revisiting the Docker and reverse proxy configurations helped identify that the container’s network settings were not correctly aligned with the host’s, which impacted the HTTPS handshake. Careful validation of these settings resolved the issue in my setup.

hey, i had similar trouble; ended up re-checking cyberpanel config and port forwarding. my reverse proxy had a slight typo in the container ip, so ssl failed. hope this helps!

Based on my experience with Docker and N8N on a CentOS server with CyberPanel, the issue was not solely a certificate problem. I discovered that CyberPanel’s configuration for custom ports can sometimes override or conflict with Docker’s settings. After inspecting the reverse proxy setup, I found that the custom port forwarding rules needed to be aligned with Docker’s internal mapping. Adjusting these settings and verifying that CyberPanel recognized the right port resolving logic significantly improved the secure connection. Detailed configuration reviews are essential in such cases.