From 72570153a58d04b76a36d94ec765a15143172208 Mon Sep 17 00:00:00 2001 From: Anthony Lapenna Date: Mon, 3 Oct 2016 12:35:40 +1300 Subject: [PATCH 1/8] docs(badges): add the dockerhub version badge --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index d53d59cbb..4c16dd5c3 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,7 @@ The easiest way to manage Docker. +[![Microbadger version](https://images.microbadger.com/badges/version/portainer/portainer.svg)](https://microbadger.com/images/portainer/portainer "Latest version on Docker Hub") [![Microbadger](https://images.microbadger.com/badges/image/portainer/portainer.svg)](http://microbadger.com/images/portainer/portainer "Image size") [![Documentation Status](https://readthedocs.org/projects/portainer/badge/?version=stable)](http://portainer.readthedocs.io/en/stable/?badge=stable) [![Gitter](https://badges.gitter.im/portainer/Lobby.svg)](https://gitter.im/portainer/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge) From 477799af7e0a0f721f2c9427f8a0d08b17af1aec Mon Sep 17 00:00:00 2001 From: Anthony Lapenna Date: Wed, 5 Oct 2016 10:44:29 +1300 Subject: [PATCH 2/8] chore(project): update contribution guidelines --- CONTRIBUTING.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 250f46d86..015abca17 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -24,10 +24,9 @@ Each commit message should include a **type**, a **scope** and a **subject**: Lines should not exceed 100 characters. This allows the message to be easier to read on github as well as in various git tools and produces a nice, neat commit log ie: ``` - #271 feat(standard): add style config and refactor to match - #270 fix(config): only override publicPath when served by webpack - #269 feat(eslint-config-defaults): replace eslint-config-airbnb - #268 feat(config): allow user to configure webpack stats output + #271 feat(containers): add exposed ports in the containers view + #270 fix(templates): fix a display issue in the templates view + #269 style(dashboard): update dashboard with new layout ``` #### Type From fde0d3ea9f11975facaca988d77d3ab9f400108e Mon Sep 17 00:00:00 2001 From: Anthony Lapenna Date: Wed, 5 Oct 2016 10:56:49 +1300 Subject: [PATCH 3/8] chore(github): add github issue template --- .github/ISSUE_TEMPLATE.md | 43 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 .github/ISSUE_TEMPLATE.md diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md new file mode 100644 index 000000000..f01c9df7e --- /dev/null +++ b/.github/ISSUE_TEMPLATE.md @@ -0,0 +1,43 @@ + + +**Description** + + + +**Steps to reproduce the issue:** + +1. +2. +3. + +Any other info e.g. Why do you consider this to be a bug? What did you expect to happen instead? + +**Technical details:** + +* Portainer version: +* Target Docker version (the host/cluster you manage): +* Target Swarm version (if applicable): +* Platform (windows/linux): +* Browser: From 8f7f4acc0de0560ac7e310c56ddbc7f1cfb95fa7 Mon Sep 17 00:00:00 2001 From: Anthony Lapenna Date: Wed, 5 Oct 2016 11:33:32 +1300 Subject: [PATCH 4/8] chore(build): add a build script to archive binary --- build.sh | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100755 build.sh diff --git a/build.sh b/build.sh new file mode 100755 index 000000000..ad0e11508 --- /dev/null +++ b/build.sh @@ -0,0 +1,16 @@ +#!/usr/bin/env bash + +VERSION=$1 + +if [[ $# -ne 1 ]] ; then + echo "Usage: $(basename $0) " + exit 1 +fi + +grunt release +rm -rf /tmp/portainer-build && mkdir -pv /tmp/portainer-build/portainer +mv dist/* /tmp/portainer-build/portainer +cd /tmp/portainer-build +tar cvpfz portainer-${VERSION}.tar.gz portainer + +exit 0 From 134416c9a33d89eb342c2456bc0302a186a2c57e Mon Sep 17 00:00:00 2001 From: Anthony Lapenna Date: Fri, 7 Oct 2016 17:19:25 +1300 Subject: [PATCH 5/8] fix(container-console): use xterm.js v2 (#262) --- .../containerConsole/containerConsoleController.js | 10 +++------- bower.json | 2 +- gruntFile.js | 4 ++-- 3 files changed, 6 insertions(+), 10 deletions(-) diff --git a/app/components/containerConsole/containerConsoleController.js b/app/components/containerConsole/containerConsoleController.js index 3f1bcd757..c02a0a84c 100644 --- a/app/components/containerConsole/containerConsoleController.js +++ b/app/components/containerConsole/containerConsoleController.js @@ -82,16 +82,14 @@ function ($scope, $stateParams, Settings, Container, Exec, $timeout, Messages) { $scope.connected = true; socket.onopen = function(evt) { $('#loadConsoleSpinner').hide(); - term = new Terminal({ - cols: width, - rows: height, - cursorBlink: true - }); + term = new Terminal(); term.on('data', function (data) { socket.send(data); }); term.open(document.getElementById('terminal-container')); + term.resize(width, height); + term.setOption('cursorBlink', true); socket.onmessage = function (e) { term.write(e.data); @@ -102,8 +100,6 @@ function ($scope, $stateParams, Settings, Container, Exec, $timeout, Messages) { }; socket.onclose = function(evt) { $scope.connected = false; - // term.write("Session terminated"); - // term.destroy(); }; }; } diff --git a/bower.json b/bower.json index 0e811c6fb..35adee30f 100644 --- a/bower.json +++ b/bower.json @@ -41,7 +41,7 @@ "lodash": "4.12.0", "rdash-ui": "1.0.*", "moment": "~2.14.1", - "xterm.js": "~1.1.3" + "xterm.js": "~2.0.1" }, "resolutions": { "angular": "1.5.5" diff --git a/gruntFile.js b/gruntFile.js index f1e4db93b..ff3acd980 100644 --- a/gruntFile.js +++ b/gruntFile.js @@ -73,7 +73,7 @@ module.exports = function (grunt) { 'bower_components/lodash/dist/lodash.min.js', 'bower_components/filesize/lib/filesize.min.js', 'bower_components/moment/min/moment.min.js', - 'bower_components/xterm.js/src/xterm.js', + 'bower_components/xterm.js/dist/xterm.js', 'assets/js/jquery.gritter.js', // Using custom version to fix error in minified build due to "use strict" 'assets/js/legend.js' // Not a bower package ], @@ -88,7 +88,7 @@ module.exports = function (grunt) { 'bower_components/font-awesome/css/font-awesome.min.css', 'bower_components/rdash-ui/dist/css/rdash.min.css', 'bower_components/angular-ui-select/dist/select.min.css', - 'bower_components/xterm.js/src/xterm.css', + 'bower_components/xterm.js/dist/xterm.css', 'bower_components/Hover/css/hover-min.css' ] }, From 35ced4901a8a867f0e6551af01ea3914b63b7c00 Mon Sep 17 00:00:00 2001 From: Anthony Lapenna Date: Fri, 7 Oct 2016 17:55:09 +1300 Subject: [PATCH 6/8] feat(global): display a message when no item available in a list view (#263) --- app/components/containers/containers.html | 3 +++ app/components/containers/containersController.js | 2 +- app/components/images/images.html | 3 +++ app/components/images/imagesController.js | 1 + app/components/networks/networks.html | 3 +++ app/components/networks/networksController.js | 1 + app/components/templates/templates.html | 3 +++ app/components/templates/templatesController.js | 1 + app/components/volumes/volumes.html | 3 +++ app/components/volumes/volumesController.js | 1 + assets/css/app.css | 4 ++-- 11 files changed, 22 insertions(+), 3 deletions(-) diff --git a/app/components/containers/containers.html b/app/components/containers/containers.html index e8f681f41..1e13ffac3 100644 --- a/app/components/containers/containers.html +++ b/app/components/containers/containers.html @@ -98,6 +98,9 @@ - + + No containers available. + diff --git a/app/components/containers/containersController.js b/app/components/containers/containersController.js index d807cc226..bbbe506d0 100644 --- a/app/components/containers/containersController.js +++ b/app/components/containers/containersController.js @@ -1,7 +1,6 @@ angular.module('containers', []) .controller('ContainersController', ['$scope', 'Container', 'ContainerHelper', 'Info', 'Settings', 'Messages', 'Config', function ($scope, Container, ContainerHelper, Info, Settings, Messages, Config) { - $scope.state = {}; $scope.state.displayAll = Settings.displayAll; $scope.state.displayIP = false; @@ -9,6 +8,7 @@ function ($scope, Container, ContainerHelper, Info, Settings, Messages, Config) $scope.sortReverse = false; $scope.state.selectedItemCount = 0; $scope.swarm_mode = false; + $scope.containers = []; $scope.order = function (sortType) { $scope.sortReverse = ($scope.sortType === sortType) ? !$scope.sortReverse : false; diff --git a/app/components/images/images.html b/app/components/images/images.html index 21fbe57db..1405432c0 100644 --- a/app/components/images/images.html +++ b/app/components/images/images.html @@ -107,6 +107,9 @@ {{ image.VirtualSize|humansize }} {{ image.Created|getisodatefromtimestamp }} + + No images available. + diff --git a/app/components/images/imagesController.js b/app/components/images/imagesController.js index 1f7e0394c..76ff6e29d 100644 --- a/app/components/images/imagesController.js +++ b/app/components/images/imagesController.js @@ -5,6 +5,7 @@ function ($scope, $state, Config, Image, Messages) { $scope.sortType = 'RepoTags'; $scope.sortReverse = true; $scope.state.selectedItemCount = 0; + $scope.images = []; $scope.config = { Image: '', diff --git a/app/components/networks/networks.html b/app/components/networks/networks.html index d0b5c9fb0..20ebf0f5b 100644 --- a/app/components/networks/networks.html +++ b/app/components/networks/networks.html @@ -131,6 +131,9 @@ {{ network.IPAM.Config[0].Subnet ? network.IPAM.Config[0].Subnet : '-' }} {{ network.IPAM.Config[0].Gateway ? network.IPAM.Config[0].Gateway : '-' }} + + No networks available. + diff --git a/app/components/networks/networksController.js b/app/components/networks/networksController.js index 84e755c07..818f4f58b 100644 --- a/app/components/networks/networksController.js +++ b/app/components/networks/networksController.js @@ -6,6 +6,7 @@ function ($scope, $state, Network, Config, Messages) { $scope.state.advancedSettings = false; $scope.sortType = 'Name'; $scope.sortReverse = false; + $scope.networks = []; $scope.config = { Name: '' diff --git a/app/components/templates/templates.html b/app/components/templates/templates.html index a53bd09af..b5a479d75 100644 --- a/app/components/templates/templates.html +++ b/app/components/templates/templates.html @@ -82,6 +82,9 @@
{{ tpl.title }}
{{ tpl.description }}
+
+ No templates available. +
diff --git a/app/components/templates/templatesController.js b/app/components/templates/templatesController.js index 3c373f1c1..dca02bbea 100644 --- a/app/components/templates/templatesController.js +++ b/app/components/templates/templatesController.js @@ -7,6 +7,7 @@ function ($scope, $q, $state, $filter, Config, Info, Container, ContainerHelper, network: "", name: "" }; + $scope.templates = []; var selectedItem = -1; diff --git a/app/components/volumes/volumes.html b/app/components/volumes/volumes.html index 701f4c761..4c3ae2072 100644 --- a/app/components/volumes/volumes.html +++ b/app/components/volumes/volumes.html @@ -59,6 +59,9 @@ {{ volume.Driver }} {{ volume.Mountpoint }} + + No volumes available. + diff --git a/app/components/volumes/volumesController.js b/app/components/volumes/volumesController.js index 90c9880e5..fc0dc8888 100644 --- a/app/components/volumes/volumesController.js +++ b/app/components/volumes/volumesController.js @@ -5,6 +5,7 @@ function ($scope, $state, Volume, Messages) { $scope.state.selectedItemCount = 0; $scope.sortType = 'Name'; $scope.sortReverse = true; + $scope.volumes = []; $scope.config = { Name: '' diff --git a/assets/css/app.css b/assets/css/app.css index c993c6230..d544242af 100644 --- a/assets/css/app.css +++ b/assets/css/app.css @@ -238,12 +238,12 @@ input[type="radio"] { } .container-template--selected { - background-color: #f6f6f6; + background-color: #ececec; color: #2d3e63; } .container-template:hover { - background-color: #f6f6f6; + background-color: #ececec; color: #2d3e63; } From 44e09ecadf761cb30a01ef943416d2f67e4f6b8e Mon Sep 17 00:00:00 2001 From: Anthony Lapenna Date: Fri, 7 Oct 2016 18:08:07 +1300 Subject: [PATCH 7/8] feat(container-creation): let Docker assign a port when host port is not specified (#264) --- app/components/createContainer/createContainerController.js | 4 ++-- app/components/createContainer/createcontainer.html | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/components/createContainer/createContainerController.js b/app/components/createContainer/createContainerController.js index 939534f58..ba3c8fe04 100644 --- a/app/components/createContainer/createContainerController.js +++ b/app/components/createContainer/createContainerController.js @@ -156,10 +156,10 @@ function ($scope, $state, Config, Info, Container, Image, Volume, Network, Messa function preparePortBindings(config) { var bindings = {}; config.HostConfig.PortBindings.forEach(function (portBinding) { - if (portBinding.hostPort && portBinding.containerPort) { + if (portBinding.containerPort) { var key = portBinding.containerPort + "/" + portBinding.protocol; var binding = {}; - if (portBinding.hostPort.indexOf(':') > -1) { + if (portBinding.hostPort && portBinding.hostPort.indexOf(':') > -1) { var hostAndPort = portBinding.hostPort.split(':'); binding.HostIp = hostAndPort[0]; binding.HostPort = hostAndPort[1]; diff --git a/app/components/createContainer/createcontainer.html b/app/components/createContainer/createcontainer.html index 508e2a03f..7a9234741 100644 --- a/app/components/createContainer/createcontainer.html +++ b/app/components/createContainer/createcontainer.html @@ -69,7 +69,7 @@
host - +
container From 520532cb9a56b11adcbcbf7c22d9512a6b8fa226 Mon Sep 17 00:00:00 2001 From: Anthony Lapenna Date: Fri, 7 Oct 2016 18:22:44 +1300 Subject: [PATCH 8/8] chore(version): bump version number --- api/main.go | 2 +- app/app.js | 2 +- bower.json | 2 +- package.json | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/api/main.go b/api/main.go index e6ad24eb2..a4dce7ec3 100644 --- a/api/main.go +++ b/api/main.go @@ -6,7 +6,7 @@ import ( // main is the entry point of the program func main() { - kingpin.Version("1.9.1") + kingpin.Version("1.9.2") var ( endpoint = kingpin.Flag("host", "Dockerd endpoint").Default("unix:///var/run/docker.sock").Short('H').String() addr = kingpin.Flag("bind", "Address and port to serve Portainer").Default(":9000").Short('p').String() diff --git a/app/app.js b/app/app.js index 8cc2eb4d7..258429903 100644 --- a/app/app.js +++ b/app/app.js @@ -188,4 +188,4 @@ angular.module('portainer', [ .constant('DOCKER_PORT', '') // Docker port, leave as an empty string if no port is requred. If you have a port, prefix it with a ':' i.e. :4243 .constant('CONFIG_ENDPOINT', 'settings') .constant('TEMPLATES_ENDPOINT', 'templates') - .constant('UI_VERSION', 'v1.9.1'); + .constant('UI_VERSION', 'v1.9.2'); diff --git a/bower.json b/bower.json index 35adee30f..d675341bc 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "portainer", - "version": "1.9.1", + "version": "1.9.2", "homepage": "https://github.com/portainer/portainer", "authors": [ "Anthony Lapenna " diff --git a/package.json b/package.json index 62bfd505b..4f1b118f1 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "author": "Portainer.io", "name": "portainer", "homepage": "http://portainer.io", - "version": "1.9.1", + "version": "1.9.2", "repository": { "type": "git", "url": "git@github.com:portainer/portainer.git"