Implement ssl with different port in nginx (LEMP stack)

My domain is:

I have successfully installed lets encrypt ssl on my site.

My server is on LEMP stack (linux, ngnix, mysql, php)

Everything is ok for now but the problem is when i install webmin it is running on different port,
How can i use that port with SSL ??

I tried to edit /etc/nginx/sites-enabled/ with this configuration

server {
    root /usr/share/webmin;


    listen 10000 ssl; # managed by Certbot
    ssl_certificate /etc/letsencrypt/live/; # managed by Certbot
    ssl_certificate_key /etc/letsencrypt/live/; # managed by Certbot
    include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
    ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot


But it failed to start the server.
I am a noob, so please tell me how can i implement ssl to 10000 port ?

Hi @kirainhere

if you install webmin, then webmin may start it's own webserver.

So if you start your own server

that can't work, port 10000 is already blocked by webmin. You have to change your webmin configuration.

Thanks for your reply Sir.

Web host manager (Cpanel) in godaddy is maybe running 2083 with ssl
I think the WHM is creating its own server, i might be wrong.
But my question is how ssl enable on port 2083 if it already a server and block by cpanel ?

@JuergenAuer I tried the solution, It not fully installed and also delete my letsencrypt certification from my server.

Can you suggest me another way ??

If you use cPanel, then you should use the integrated solution there. works, doesn't work, but that may be a problem of the firewall or something else.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.