SSL for hostname with letsencrypt

Tazmanian79

Verified User
Joined
Jul 24, 2010
Messages
106
Just need a little information before I try to install a SSL certificate for my hostname.

This is my situation (CentOs 7 all latest versions)

(www.)domain.com is used for website and has SSL by Gandi
(www.)domain2.com is used for website and has SSL by Gandi
(www.)domain3.com is used for website and has SSL by Letsencrypt

But now I want also an SSL for my hostname srv.domain.com (same domain as my main website that has SSL by Gandi)


I should follow these instructions: https://help.directadmin.com/item.php?id=629

1.
Code:
cd /usr/local/directadmin/scripts
./letsencrypt.sh request_single srv.domain.com 4096

But then there are these instructions:
cd /usr/local/directadmin/conf
perl -pi -e 's/SSL=0/SSL=1/' directadmin.conf
---> This is to setup Directadmin over SSL, but I don't want this (yet) so I can just ignore this?

echo "carootcert=/usr/local/directadmin/conf/carootcert.pem" >> directadmin.conf
---> What does this do? Is this necessary if I don't do the previous step?

echo "force_hostname=your.hostname.com" >> directadmin.conf
---> What does this do? Is this necessary if I don't do the previous step?

echo "ssl_redirect_host=your.hostname.com" >> directadmin.conf
---> What does this do? Is this necessary if I don't do the previous step?

service directadmin restart


Thanks for your advice/info.
 
Hello,

---> This is to setup Directadmin over SSL, but I don't want this (yet) so I can just ignore this?

Yes, that's correct. If you want to use insecure way to connect to Directadmin you can ignore this step.

---> What does this do? Is this necessary if I don't do the previous step?

No, it's not.

---> What does this do? Is this necessary if I don't do the previous step?

No, it's not.

---> What does this do? Is this necessary if I don't do the previous step?

No, it's not.
 
Simple Script for Creating SSL Certificate for hostname

Hi..
I have create simple script to create hostname:

Code:
#!/bin/sh
myhostname=$(cat /etc/hostname)
echo "====================================="
echo "Generate SSL Certificate for hostname"
echo "====================================="
echo "Hostname: $myhostname"
cd /usr/local/directadmin/scripts
./letsencrypt.sh request_single $myhostname 4096
cd /usr/local/directadmin/conf
cd /usr/local/directadmin
./directadmin set SSL 1
./directadmin set carootcert /usr/local/directadmin/conf/carootcert.pem
./directadmin set force_hostname $myhostname
./directadmin set ssl_redirect_host $myhostname
service directadmin restart

may be useful
 
Simple Script for Creating SSL Certificate for hostname

Hi..
I have create simple script to create hostname:

Code:
#!/bin/sh
myhostname=$(cat /etc/hostname)
echo "====================================="
echo "Generate SSL Certificate for hostname"
echo "====================================="
echo "Hostname: $myhostname"
cd /usr/local/directadmin/scripts
./letsencrypt.sh request_single $myhostname 4096
cd /usr/local/directadmin/conf
cd /usr/local/directadmin
./directadmin set SSL 1
./directadmin set carootcert /usr/local/directadmin/conf/carootcert.pem
./directadmin set force_hostname $myhostname
./directadmin set ssl_redirect_host $myhostname
service directadmin restart

may be useful
Thanks it's useful
 
Back
Top