Add let's encrypt to customer domain - GUI

Signed-off-by: Florian Aders <eleras@froxlor.org>
This commit is contained in:
Florian Aders
2016-01-30 13:59:34 +01:00
parent e0e1085c73
commit 44d08d6aa9
8 changed files with 95 additions and 21 deletions

View File

@@ -75,6 +75,11 @@ class lescript
public function signDomains(array $domains, $domainkey = null)
{
if (!$this->accountKey) {
throw new \RuntimeException("Account not initiated");
}
$this->log('Starting certificate generation process for domains');
$privateAccountKey = openssl_pkey_get_private($this->accountKey);

View File

@@ -70,6 +70,16 @@ return array(
),
'value' => array()
),
'useletsencrypt' => array(
'visible' => (Settings::Get('system.use_ssl') == '1' ? ($ssl_ipsandports != '' ? true : false) : false),
'label' => $lng['domains']['letsencrypt']['title'],
'desc' => $lng['domains']['letsencrypt']['description'],
'type' => 'checkbox',
'values' => array(
array ('label' => $lng['panel']['yes'], 'value' => '1')
),
'value' => array()
),
'openbasedir_path' => array(
'label' => $lng['domain']['openbasedirpath'],
'type' => 'select',

View File

@@ -86,6 +86,16 @@ return array(
),
'value' => array($result['ssl_redirect'])
),
'useletsencrypt' => array(
'visible' => (Settings::Get('system.use_ssl') == '1' ? ($ssl_ipsandports != '' ? (domainHasSslIpPort($result['id']) ? true : false) : false) : false),
'label' => $lng['domains']['letsencrypt']['title'],
'desc' => $lng['domains']['letsencrypt']['description'],
'type' => 'checkbox',
'values' => array(
array ('label' => $lng['panel']['yes'], 'value' => '1')
),
'value' => array($result['letsencrypt'])
),
'openbasedir_path' => array(
'visible' => ($result['openbasedir'] == '1') ? true : false,
'label' => $lng['domain']['openbasedirpath'],