2018-08-02 05:48:47 -04:00
|
|
|
<div class="modal-content">
|
|
|
|
<div class="modal-header">
|
2018-08-07 06:27:20 -04:00
|
|
|
<h5 class="modal-title"><%- i18n('certificates', 'form-title', {provider: provider}) %></h5>
|
2018-08-02 05:48:47 -04:00
|
|
|
<button type="button" class="close cancel" aria-label="Close" data-dismiss="modal"> </button>
|
|
|
|
</div>
|
2018-08-07 06:27:20 -04:00
|
|
|
<div class="modal-body">
|
2018-08-02 05:48:47 -04:00
|
|
|
<form>
|
2018-08-07 06:27:20 -04:00
|
|
|
<div class="row">
|
|
|
|
<% if (provider === 'letsencrypt') { %>
|
|
|
|
<div class="col-sm-12 col-md-12">
|
|
|
|
<div class="form-group">
|
|
|
|
<label class="form-label"><%- i18n('all-hosts', 'domain-names') %> <span class="form-required">*</span></label>
|
|
|
|
<input type="text" name="domain_names" class="form-control" id="input-domains" value="<%- domain_names.join(',') %>" required>
|
|
|
|
<div class="text-blue"><i class="fe fe-alert-triangle"></i> <%- i18n('ssl', 'hosts-warning') %></div>
|
2018-08-02 05:48:47 -04:00
|
|
|
</div>
|
|
|
|
</div>
|
2018-08-07 06:27:20 -04:00
|
|
|
<div class="col-sm-12 col-md-12">
|
|
|
|
<div class="form-group">
|
|
|
|
<label class="form-label"><%- i18n('ssl', 'letsencrypt-email') %> <span class="form-required">*</span></label>
|
|
|
|
<input name="meta[letsencrypt_email]" type="email" class="form-control" placeholder="" value="<%- getLetsencryptEmail() %>" required>
|
2018-08-02 05:48:47 -04:00
|
|
|
</div>
|
2018-08-07 06:27:20 -04:00
|
|
|
</div>
|
2020-08-23 07:40:41 -04:00
|
|
|
|
2020-10-04 17:56:02 -04:00
|
|
|
<!-- DNS challenge -->
|
2020-08-23 07:40:41 -04:00
|
|
|
<div class="col-sm-12 col-md-12">
|
|
|
|
<div class="form-group">
|
|
|
|
<label class="custom-switch">
|
2020-10-04 17:56:02 -04:00
|
|
|
<input
|
|
|
|
type="checkbox"
|
|
|
|
class="custom-switch-input"
|
|
|
|
name="meta[dns_challenge]"
|
|
|
|
value="1"
|
|
|
|
<%- getUseDnsChallenge() ? 'checked' : '' %>
|
|
|
|
>
|
2020-08-23 07:40:41 -04:00
|
|
|
<span class="custom-switch-indicator"></span>
|
2020-10-04 17:56:02 -04:00
|
|
|
<span class="custom-switch-description"><%= i18n('ssl', 'dns-challenge') %></span>
|
2020-08-23 07:40:41 -04:00
|
|
|
</label>
|
|
|
|
</div>
|
|
|
|
</div>
|
2020-10-04 17:56:02 -04:00
|
|
|
<div class="col-sm-12 col-md-12">
|
|
|
|
<fieldset class="form-fieldset dns-challenge">
|
|
|
|
<div class="text-red mb-4"><i class="fe fe-alert-triangle"></i> <%= i18n('ssl', 'certbot-warning') %></div>
|
|
|
|
|
|
|
|
<!-- Certbot DNS plugin selection -->
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-sm-12 col-md-12">
|
|
|
|
<div class="form-group">
|
|
|
|
<label class="form-label"><%- i18n('ssl', 'dns-provider') %> <span class="form-required">*</span></label>
|
|
|
|
<select
|
|
|
|
name="meta[dns_provider]"
|
|
|
|
id="dns_provider"
|
|
|
|
class="form-control custom-select"
|
|
|
|
>
|
|
|
|
<option
|
|
|
|
value=""
|
|
|
|
disabled
|
|
|
|
hidden
|
|
|
|
<%- getDnsProvider() === null ? 'selected' : '' %>
|
|
|
|
>Please Choose...</option>
|
|
|
|
<% _.each(dns_plugins, function(plugin_info, plugin_name){ %>
|
|
|
|
<option
|
|
|
|
value="<%- plugin_name %>"
|
|
|
|
<%- getDnsProvider() === plugin_name ? 'selected' : '' %>
|
|
|
|
><%- plugin_info.display_name %></option>
|
|
|
|
<% }); %>
|
|
|
|
</select>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- Certbot credentials file content -->
|
|
|
|
<div class="row credentials-file-content">
|
|
|
|
<div class="col-sm-12 col-md-12">
|
|
|
|
<div class="form-group">
|
|
|
|
<label class="form-label"><%- i18n('ssl', 'credentials-file-content') %> <span class="form-required">*</span></label>
|
|
|
|
<textarea
|
|
|
|
name="meta[dns_provider_credentials]"
|
|
|
|
class="form-control text-monospace"
|
|
|
|
id="dns_provider_credentials"
|
|
|
|
><%- getDnsProviderCredentials() %></textarea>
|
|
|
|
<div class="text-secondary small">
|
|
|
|
<i class="fe fe-info"></i>
|
|
|
|
<%= i18n('ssl', 'credentials-file-content-info') %>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<!-- DNS propagation delay -->
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-sm-12 col-md-12">
|
|
|
|
<div class="form-group mb-0">
|
|
|
|
<label class="form-label"><%- i18n('ssl', 'propagation-seconds') %></label>
|
|
|
|
<input
|
|
|
|
type="number"
|
|
|
|
min="0"
|
|
|
|
name="meta[propagation_seconds]"
|
|
|
|
class="form-control"
|
|
|
|
id="propagation_seconds"
|
|
|
|
value="<%- getPropagationSeconds() %>"
|
|
|
|
>
|
|
|
|
<div class="text-secondary small">
|
|
|
|
<i class="fe fe-info"></i>
|
|
|
|
<%= i18n('ssl', 'propagation-seconds-info') %>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</fieldset>
|
2020-08-23 07:40:41 -04:00
|
|
|
</div>
|
|
|
|
|
2018-08-07 06:27:20 -04:00
|
|
|
<div class="col-sm-12 col-md-12">
|
|
|
|
<div class="form-group">
|
|
|
|
<label class="custom-switch">
|
|
|
|
<input type="checkbox" class="custom-switch-input" name="meta[letsencrypt_agree]" value="1" required<%- getLetsencryptAgree() ? ' checked' : '' %>>
|
|
|
|
<span class="custom-switch-indicator"></span>
|
|
|
|
<span class="custom-switch-description"><%= i18n('ssl', 'letsencrypt-agree', {url: 'https://letsencrypt.org/repository/'}) %> <span class="form-required">*</span></span>
|
|
|
|
</label>
|
2018-08-02 05:48:47 -04:00
|
|
|
</div>
|
2018-08-07 06:27:20 -04:00
|
|
|
</div>
|
|
|
|
<% } else if (provider === 'other') { %>
|
|
|
|
<!-- Other -->
|
|
|
|
<div class="col-sm-12 col-md-12">
|
|
|
|
<div class="form-group">
|
|
|
|
<label class="form-label"><%- i18n('str', 'name') %> <span class="form-required">*</span></label>
|
|
|
|
<input name="nice_name" type="text" class="form-control" placeholder="" value="<%- nice_name %>" required>
|
2018-08-02 05:48:47 -04:00
|
|
|
</div>
|
2018-08-07 06:27:20 -04:00
|
|
|
</div>
|
|
|
|
<div class="col-sm-12 col-md-12 other-ssl">
|
|
|
|
<div class="form-group">
|
2018-08-08 02:58:21 -04:00
|
|
|
<div class="form-label"><%- i18n('certificates', 'other-certificate-key') %><span class="form-required">*</span></div>
|
2018-08-07 06:27:20 -04:00
|
|
|
<div class="custom-file">
|
2018-08-08 02:58:21 -04:00
|
|
|
<input type="file" class="custom-file-input" name="meta[other_certificate_key]" id="other_certificate_key" required>
|
2020-08-29 23:24:51 -04:00
|
|
|
<label id="other_certificate_key_label" class="custom-file-label"><%- i18n('str', 'choose-file') %></label>
|
2018-08-02 05:48:47 -04:00
|
|
|
</div>
|
|
|
|
</div>
|
2018-08-07 06:27:20 -04:00
|
|
|
</div>
|
|
|
|
<div class="col-sm-12 col-md-12 other-ssl">
|
|
|
|
<div class="form-group">
|
2018-08-08 02:58:21 -04:00
|
|
|
<div class="form-label"><%- i18n('certificates', 'other-certificate') %><span class="form-required">*</span></div>
|
2018-08-07 06:27:20 -04:00
|
|
|
<div class="custom-file">
|
2018-08-08 02:58:21 -04:00
|
|
|
<input type="file" class="custom-file-input" name="meta[other_certificate]" id="other_certificate">
|
2020-08-29 23:24:51 -04:00
|
|
|
<label id="other_certificate_label" class="custom-file-label"><%- i18n('str', 'choose-file') %></label>
|
2018-08-02 05:48:47 -04:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2018-08-08 02:58:21 -04:00
|
|
|
<div class="col-sm-12 col-md-12 other-ssl">
|
|
|
|
<div class="form-group">
|
|
|
|
<div class="form-label"><%- i18n('certificates', 'other-intermediate-certificate') %></div>
|
|
|
|
<div class="custom-file">
|
|
|
|
<input type="file" class="custom-file-input" name="meta[other_intermediate_certificate]" id="other_intermediate_certificate">
|
2020-08-29 23:24:51 -04:00
|
|
|
<label id="other_intermediate_certificate_label" class="custom-file-label"><%- i18n('str', 'choose-file') %></label>
|
2018-08-08 02:58:21 -04:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
2018-08-07 06:27:20 -04:00
|
|
|
<% } %>
|
2018-08-02 05:48:47 -04:00
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
<div class="modal-footer">
|
|
|
|
<button type="button" class="btn btn-secondary cancel" data-dismiss="modal"><%- i18n('str', 'cancel') %></button>
|
|
|
|
<button type="button" class="btn btn-teal save"><%- i18n('str', 'save') %></button>
|
|
|
|
</div>
|
|
|
|
</div>
|