Fix the build package path handling
This commit is contained in:
parent
9a733a7320
commit
256503ca75
2 changed files with 5 additions and 5 deletions
|
@ -825,8 +825,8 @@ function BuildPackageCtrl($scope, Restangular, ApiService, $routeParams, $rootSc
|
|||
if (dockerfileFolder[0] == '/') {
|
||||
dockerfileFolder = dockerfileFolder.substr(1);
|
||||
}
|
||||
if (dockerfileFolder[dockerfileFolder.length - 1] == '/') {
|
||||
dockerfileFolder = dockerfileFolder.substr(0, dockerfileFolder.length - 1);
|
||||
if (dockerfileFolder && dockerFileFolder[dockerFileFolder.length - 1] != '/') {
|
||||
dockerfileFolder += '/';
|
||||
}
|
||||
|
||||
dockerfilePath = dockerfileFolder + 'Dockerfile';
|
||||
|
|
|
@ -37,9 +37,9 @@
|
|||
<div class="tab-content">
|
||||
<!-- Dockerfile view -->
|
||||
<div class="tab-pane active" id="dockerfile">
|
||||
<div class="dockerfile-path">{{ dockerFilePath }}</div>
|
||||
<div class="dockerfile-view" contents="dockerFileContents"></div>
|
||||
<span ng-show="!dockerFileContents">No Dockerfile found in the build pack</span>
|
||||
<div class="dockerfile-path" ng-if="dockerFileContents">{{ dockerFilePath }}</div>
|
||||
<div class="dockerfile-view" contents="dockerFileContents" ng-if="dockerFileContents"></div>
|
||||
<span ng-if="!dockerFileContents">No Dockerfile found in the build pack</span>
|
||||
</div>
|
||||
|
||||
<!-- File tree -->
|
||||
|
|
Reference in a new issue