Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Let users specify HTTPS when editing health checks #1087

Merged
merged 1 commit into from
Jan 6, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/scripts/directives/editProbe.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ angular.module('openshiftConsole')

scope.types = [{
id: 'httpGet',
label: 'HTTP'
label: 'HTTP GET'
}, {
id: 'exec',
label: 'Container Command'
Expand Down
12 changes: 12 additions & 0 deletions app/views/directives/_edit-probe.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,18 @@
</ui-select>
</div>
<fieldset ng-if="selected.type === 'httpGet'">
<div class="form-group">
<div class="checkbox">
<label>
<input
type="checkbox"
ng-model="probe.httpGet.scheme"
ng-true-value=" 'HTTPS' "
ng-false-value=" 'HTTP' ">
Use HTTPS
</label>
</div>
</div>
<div class="form-group">
<label ng-attr-for="{{id}}-path">Path</label>
<div>
Expand Down
2 changes: 1 addition & 1 deletion app/views/directives/_probe.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<!-- Make sure there is no whitespace before comma -->
<span ng-if="probe.httpGet">
GET {{probe.httpGet.path || '/'}} on port {{probe.httpGet.port || 'unknown'}}
GET {{probe.httpGet.path || '/'}} on port {{probe.httpGet.port || 'unknown'}} ({{probe.httpGet.scheme || 'HTTP'}})
</span>
<span ng-if="probe.exec.command">
<code class="command">
Expand Down
4 changes: 2 additions & 2 deletions app/views/edit/health-checks.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ <h1>Health Checks: {{name}}</h1>
<div ng-repeat="container in containers">
<h2 ng-if="containers.length > 1">Container {{container.name}}</h2>
<h3>Readiness Probe</h3>
<div class="help-block" ng-if="$first">
<div class="help-block mar-bottom-md" ng-if="$first">
A readiness probe checks if the container is ready to handle requests. A
failed readiness probe means that a container should not receive any traffic
from a proxy, even if it's running.
Expand All @@ -45,7 +45,7 @@ <h3>Readiness Probe</h3>
</p>
</div>
<h3>Liveness Probe</h3>
<div class="help-block" ng-if="$first">
<div class="help-block mar-bottom-md" ng-if="$first">
A liveness probe checks if the container is still running. If the liveness
probe fails, the container is killed.
</div>
Expand Down
2 changes: 1 addition & 1 deletion dist/scripts/scripts.js
Original file line number Diff line number Diff line change
Expand Up @@ -12443,7 +12443,7 @@ templateUrl:"views/directives/_edit-probe.html",
link:function(a) {
a.id = _.uniqueId("edit-probe-"), a.probe = a.probe || {}, a.types = [ {
id:"httpGet",
label:"HTTP"
label:"HTTP GET"
}, {
id:"exec",
label:"Container Command"
Expand Down
14 changes: 11 additions & 3 deletions dist/scripts/templates.js
Original file line number Diff line number Diff line change
Expand Up @@ -5567,6 +5567,14 @@ angular.module('openshiftConsoleTemplates', []).run(['$templateCache', function(
"</div>\n" +
"<fieldset ng-if=\"selected.type === 'httpGet'\">\n" +
"<div class=\"form-group\">\n" +
"<div class=\"checkbox\">\n" +
"<label>\n" +
"<input type=\"checkbox\" ng-model=\"probe.httpGet.scheme\" ng-true-value=\" 'HTTPS' \" ng-false-value=\" 'HTTP' \">\n" +
"Use HTTPS\n" +
"</label>\n" +
"</div>\n" +
"</div>\n" +
"<div class=\"form-group\">\n" +
"<label ng-attr-for=\"{{id}}-path\">Path</label>\n" +
"<div>\n" +
"<input ng-attr-id=\"{{id}}-path\" ng-model=\"probe.httpGet.path\" type=\"text\" placeholder=\"/\" autocorrect=\"off\" autocapitalize=\"off\" spellcheck=\"false\" class=\"form-control\">\n" +
Expand Down Expand Up @@ -5677,7 +5685,7 @@ angular.module('openshiftConsoleTemplates', []).run(['$templateCache', function(

$templateCache.put('views/directives/_probe.html',
" <span ng-if=\"probe.httpGet\">\n" +
"GET {{probe.httpGet.path || '/'}} on port {{probe.httpGet.port || 'unknown'}}\n" +
"GET {{probe.httpGet.path || '/'}} on port {{probe.httpGet.port || 'unknown'}} ({{probe.httpGet.scheme || 'HTTP'}})\n" +
"</span>\n" +
"<span ng-if=\"probe.exec.command\">\n" +
"<code class=\"command\">\n" +
Expand Down Expand Up @@ -9207,7 +9215,7 @@ angular.module('openshiftConsoleTemplates', []).run(['$templateCache', function(
"<div ng-repeat=\"container in containers\">\n" +
"<h2 ng-if=\"containers.length > 1\">Container {{container.name}}</h2>\n" +
"<h3>Readiness Probe</h3>\n" +
"<div class=\"help-block\" ng-if=\"$first\">\n" +
"<div class=\"help-block mar-bottom-md\" ng-if=\"$first\">\n" +
"A readiness probe checks if the container is ready to handle requests. A failed readiness probe means that a container should not receive any traffic from a proxy, even if it's running.\n" +
"</div>\n" +
"<div ng-if=\"!container.readinessProbe\">\n" +
Expand All @@ -9221,7 +9229,7 @@ angular.module('openshiftConsoleTemplates', []).run(['$templateCache', function(
"</p>\n" +
"</div>\n" +
"<h3>Liveness Probe</h3>\n" +
"<div class=\"help-block\" ng-if=\"$first\">\n" +
"<div class=\"help-block mar-bottom-md\" ng-if=\"$first\">\n" +
"A liveness probe checks if the container is still running. If the liveness probe fails, the container is killed.\n" +
"</div>\n" +
"<div ng-if=\"!container.livenessProbe\">\n" +
Expand Down