toggle redirect
parent
cd0b0b4be6
commit
72740475a7
|
@ -35,6 +35,7 @@
|
||||||
https: false,
|
https: false,
|
||||||
http2: true,
|
http2: true,
|
||||||
|
|
||||||
|
redirect: true,
|
||||||
force_https: true,
|
force_https: true,
|
||||||
|
|
||||||
cert_type: 'letsencrypt',
|
cert_type: 'letsencrypt',
|
||||||
|
@ -292,6 +293,10 @@
|
||||||
return !$scope.isNonWWW();
|
return !$scope.isNonWWW();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
$scope.isRedirect = function() {
|
||||||
|
return $scope.data.redirect;
|
||||||
|
};
|
||||||
|
|
||||||
$scope.isCDN = function() {
|
$scope.isCDN = function() {
|
||||||
return $scope.isWWW() && $scope.data.cdn;
|
return $scope.isWWW() && $scope.data.cdn;
|
||||||
};
|
};
|
||||||
|
|
|
@ -62,6 +62,14 @@
|
||||||
<span tooltips tooltip-template="Serve requests without www subdomain.">non-www</span>
|
<span tooltips tooltip-template="Serve requests without www subdomain.">non-www</span>
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="form-subgroup" ng-cloak>
|
||||||
|
<div class="form-check">
|
||||||
|
<input class="form-check-input" type="checkbox" id="redirect" ng-model="data.redirect">
|
||||||
|
<label class="form-check-label" for="redirect">
|
||||||
|
<span tooltips tooltip-template="Redirect {{ isWWW() ? 'non-www version and ' : '' }}all subdomains to domain.">redirect <small>{{ isWWW() ? 'non-www, ' : '' }}subdomains</small></span>
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<div class="form-subgroup" ng-if="isWWW()" ng-cloak>
|
<div class="form-subgroup" ng-if="isWWW()" ng-cloak>
|
||||||
<div class="form-check">
|
<div class="form-check">
|
||||||
<input class="form-check-input" type="checkbox" id="cdn" ng-model="data.cdn">
|
<input class="form-check-input" type="checkbox" id="cdn" ng-model="data.cdn">
|
||||||
|
|
|
@ -123,12 +123,12 @@ server {
|
||||||
location / {
|
location / {
|
||||||
deny all;
|
deny all;
|
||||||
}
|
}
|
||||||
}</span>
|
}</span><!--
|
||||||
<!--
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
-->
|
✔ redirect --><span ng-if="isRedirect()">
|
||||||
|
|
||||||
# {{ isWWW() ? 'non-www, ' : '' }}subdomains redirect
|
# {{ isWWW() ? 'non-www, ' : '' }}subdomains redirect
|
||||||
server {
|
server {
|
||||||
listen {{ data.ipv4 !== '*' ? data.ipv4 + ':' : '' }}{{ isHTTPS() ? '443 ssl' : '80' }}{{ isHTTP2() ? ' http2' : '' }};<!--
|
listen {{ data.ipv4 !== '*' ? data.ipv4 + ':' : '' }}{{ isHTTPS() ? '443 ssl' : '80' }}{{ isHTTP2() ? ' http2' : '' }};<!--
|
||||||
|
|
Loading…
Reference in New Issue