Merge branch 'release/1.19.1'

pull/2218/head 1.19.1
Anthony Lapenna 2018-07-28 19:46:14 +02:00
commit e94a725a8a
9 changed files with 27 additions and 27 deletions

View File

@ -611,7 +611,7 @@ type (
const (
// APIVersion is the version number of the Portainer API.
APIVersion = "1.19.0"
APIVersion = "1.19.1"
// DBVersion is the version number of the Portainer database.
DBVersion = 13
// PortainerAgentHeader represents the name of the header available in any agent response

View File

@ -54,7 +54,7 @@ info:
**NOTE**: You can find more information on how to query the Docker API in the [Docker official documentation](https://docs.docker.com/engine/api/v1.30/) as well as in [this Portainer example](https://gist.github.com/deviantony/77026d402366b4b43fa5918d41bc42f8).
version: "1.19.0"
version: "1.19.1"
title: "Portainer API"
contact:
email: "info@portainer.io"
@ -2816,7 +2816,7 @@ definitions:
description: "Is analytics enabled"
Version:
type: "string"
example: "1.19.0"
example: "1.19.1"
description: "Portainer API version"
PublicSettingsInspectResponse:
type: "object"

View File

@ -15,7 +15,7 @@ function ($scope, $state, $transition$, $sanitize, Authentication, UserService,
function unauthenticatedFlow() {
EndpointService.endpoints()
.then(function success(data) {
.then(function success(endpoints) {
if (endpoints.length === 0) {
$state.go('portainer.init.endpoint');
} else {

View File

@ -30,7 +30,7 @@
title-text="Endpoints" title-icon="fa-plug"
endpoints="endpoints"
dashboard-action="goToDashboard"
show-snapshot-action="isAdmin"
show-snapshot-action="!applicationState.application.authentication || isAdmin"
snapshot-action="triggerSnapshot"
></endpoint-list>
</div>

View File

@ -16,17 +16,20 @@ function ($q, $scope, StateManager, Notifications, Authentication, UserService)
$scope.uiVersion = StateManager.getState().application.version;
$scope.logo = StateManager.getState().application.logo;
var userDetails = Authentication.getUserDetails();
var isAdmin = userDetails.role === 1;
$scope.isAdmin = isAdmin;
var authenticationEnabled = $scope.applicationState.application.authentication;
if (authenticationEnabled) {
var userDetails = Authentication.getUserDetails();
var isAdmin = userDetails.role === 1;
$scope.isAdmin = isAdmin;
$q.when(!isAdmin ? UserService.userMemberships(userDetails.ID) : [])
.then(function success(data) {
checkPermissions(data);
})
.catch(function error(err) {
Notifications.error('Failure', err, 'Unable to retrieve user memberships');
});
$q.when(!isAdmin ? UserService.userMemberships(userDetails.ID) : [])
.then(function success(data) {
checkPermissions(data);
})
.catch(function error(err) {
Notifications.error('Failure', err, 'Unable to retrieve user memberships');
});
}
}
initView();

View File

@ -14,7 +14,7 @@ function build_and_push_images() {
function build_archive() {
BUILD_FOLDER="${ARCHIVE_BUILD_FOLDER}/$1"
rm -rf ${BUILD_FOLDER} && mkdir -pv ${BUILD_FOLDER}/portainer
mv dist/* ${BUILD_FOLDER}/portainer/
cp -r dist/* ${BUILD_FOLDER}/portainer/
cd ${BUILD_FOLDER}
tar cvpfz "portainer-${VERSION}-$1.tar.gz" portainer
mv "portainer-${VERSION}-$1.tar.gz" ${ARCHIVE_BUILD_FOLDER}/

View File

@ -1,5 +1,5 @@
Name: portainer
Version: 1.19.0
Version: 1.19.1
Release: 0
License: Zlib
Summary: A lightweight docker management UI

View File

@ -31,7 +31,6 @@ module.exports = function (grunt) {
'clean:all',
'before-copy',
'copy:assets',
'copy:templates',
'after-copy'
]);
grunt.registerTask('build', [
@ -82,6 +81,7 @@ module.exports = function (grunt) {
root: 'dist',
distdir: 'dist/public',
shippedDockerVersion: '18.03.1-ce',
shippedDockerVersionWindows: '17.09.0-ce',
pkg: grunt.file.readJSON('package.json'),
config: gruntfile_cfg.config,
src: gruntfile_cfg.src,
@ -122,7 +122,7 @@ gruntfile_cfg.src = {
};
gruntfile_cfg.clean = {
all: ['<%= distdir %>/../*'],
all: ['<%= root %>/*'],
app: ['<%= distdir %>/*', '!<%= distdir %>/../portainer*', '!<%= distdir %>/../docker*'],
tmpl: ['<%= distdir %>/templates'],
tmp: ['<%= distdir %>/js/*', '!<%= distdir %>/js/app.*.js', '<%= distdir %>/css/*', '!<%= distdir %>/css/app.*.css']
@ -163,12 +163,8 @@ gruntfile_cfg.copy = {
{dest: '<%= distdir %>/fonts/', src: '*.{ttf,woff,woff2,eof,eot,svg}', expand: true, cwd: 'node_modules/@fortawesome/fontawesome-free-webfonts/webfonts/'},
{dest: '<%= distdir %>/fonts/', src: '*.{ttf,woff,woff2,eof,svg}', expand: true, cwd: 'node_modules/rdash-ui/dist/fonts/'},
{dest: '<%= distdir %>/images/', src: '**', expand: true, cwd: 'assets/images/'},
{dest: '<%= distdir %>/ico', src: '**', expand: true, cwd: 'assets/ico'}
]
},
templates: {
files: [
{ dest: '<%= root %>/', src: 'templates.json', cwd: '' }
{dest: '<%= distdir %>/ico', src: '**', expand: true, cwd: 'assets/ico'},
{dest: '<%= root %>/', src: 'templates.json', cwd: ''}
]
}
};
@ -285,11 +281,12 @@ function shell_downloadDockerBinary(p, a) {
var as = { 'amd64': 'x86_64', 'arm': 'armhf', 'arm64': 'aarch64' };
var ip = ((ps[p] === undefined) ? p : ps[p]);
var ia = ((as[a] === undefined) ? a : as[a]);
var binaryVersion = (( p === 'win' ? '<%= shippedDockerVersionWindows %>' : '<%= shippedDockerVersion %>' ));
return [
'if [ -f '+(( p === 'win' ) ? 'dist/docker.exe' : 'dist/docker')+' ]; then',
'echo "Docker binary exists";',
'else',
'build/download_docker_binary.sh ' + ip + ' ' + ia + ' <%= shippedDockerVersion %>;',
'build/download_docker_binary.sh ' + ip + ' ' + ia + ' ' + binaryVersion + ';',
'fi'
].join(' ');
}

View File

@ -2,7 +2,7 @@
"author": "Portainer.io",
"name": "portainer",
"homepage": "http://portainer.io",
"version": "1.19.0",
"version": "1.19.1",
"repository": {
"type": "git",
"url": "git@github.com:portainer/portainer.git"