From 7d0d63e5c374251742a7835710458f107f412389 Mon Sep 17 00:00:00 2001 From: Jeffrey Morgan Date: Thu, 4 Jun 2015 20:13:21 -0700 Subject: [PATCH 01/12] Update CONTRIBUTING.md --- CONTRIBUTING.md | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index cf4dbb202e..e0b8dcc753 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -18,14 +18,21 @@ Before you fil an issue or a pull request, quickly read of the following tips on ### Prerequisites Most of the time, you'll have installed Kitematic before contibuting, but for the -sake of completeness, you can also install [Node.js](https://nodejs.org/) and the latest Xcode from the Apple App Store and then run from your Git clone. +sake of completeness, you can also install [Node.js 0.10.38](https://nodejs.org/dist/v0.10.38/). Running `npm start` will download and install the OS X Docker client, -[Docker machine](https://github.com/docker/machine), +[Docker Machine](https://github.com/docker/machine), [Docker Compose](https://github.com/docker/compose) the [Boot2Docker iso](https://github.com/boot2docker/boot2docker), [Electron](http://electron.atom.io/), and [VirtualBox](https://www.virtualbox.org/) if needed. +### Other Prerequisites (Mac) +- The latest Xcode from the Apple App Store. + +### Other Prerequisites (Windows) +- [Visual Studio 2013 Community](https://www.visualstudio.com/en-us/products/visual-studio-community-vs.aspx) (or similar) +- [Python](https://www.python.org/downloads/release/python-2710/) + ### Getting Started - `npm install` From 42b6271a3429dd3faab03b1c8ecc1d5492c4dd47 Mon Sep 17 00:00:00 2001 From: Jeffrey Morgan Date: Thu, 4 Jun 2015 20:13:34 -0700 Subject: [PATCH 02/12] Update CONTRIBUTING.md --- CONTRIBUTING.md | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e0b8dcc753..4efcb24534 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -20,12 +20,6 @@ Before you fil an issue or a pull request, quickly read of the following tips on Most of the time, you'll have installed Kitematic before contibuting, but for the sake of completeness, you can also install [Node.js 0.10.38](https://nodejs.org/dist/v0.10.38/). -Running `npm start` will download and install the OS X Docker client, -[Docker Machine](https://github.com/docker/machine), [Docker Compose](https://github.com/docker/compose) -the [Boot2Docker iso](https://github.com/boot2docker/boot2docker), -[Electron](http://electron.atom.io/), and [VirtualBox](https://www.virtualbox.org/) -if needed. - ### Other Prerequisites (Mac) - The latest Xcode from the Apple App Store. @@ -35,6 +29,7 @@ if needed. ### Getting Started + - `npm install` To run the app in development: From 9628a00ab25c72880393903067e3b5d4b51bd5aa Mon Sep 17 00:00:00 2001 From: Jeffrey Morgan Date: Thu, 4 Jun 2015 20:14:23 -0700 Subject: [PATCH 03/12] Update CONTRIBUTING.md --- CONTRIBUTING.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 4efcb24534..8fc1617a3d 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -29,13 +29,17 @@ sake of completeness, you can also install [Node.js 0.10.38](https://nodejs.org/ ### Getting Started - - `npm install` To run the app in development: - `npm start` +Running `npm start` will download and install the OS X Docker client, +[Docker Machine](https://github.com/docker/machine), [Docker Compose](https://github.com/docker/compose) +the [Boot2Docker iso](https://github.com/boot2docker/boot2docker), +[Electron](http://electron.atom.io/). + ### Building & Release - `npm run release` From 955a43a14dfb232701650c95ebf5094c6fc9709c Mon Sep 17 00:00:00 2001 From: Vojta Bartos Date: Fri, 5 Jun 2015 10:11:04 +0200 Subject: [PATCH 04/12] Fix bug where we want to set custom shell - at container details sub header - tried to access to array like object - added reduce function to make array object --- src/components/ContainerDetailsSubheader.react.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/components/ContainerDetailsSubheader.react.js b/src/components/ContainerDetailsSubheader.react.js index bc9d4a348d..c34ccd6de8 100644 --- a/src/components/ContainerDetailsSubheader.react.js +++ b/src/components/ContainerDetailsSubheader.react.js @@ -102,7 +102,11 @@ var ContainerDetailsSubheader = React.createClass({ if (!this.disableTerminal()) { metrics.track('Terminaled Into Container'); var container = this.props.container; - var shell = ContainerUtil.env(container).SHELL; + var shell = ContainerUtil.env(container).reduce((envs, env) => { + envs[env[0]] = env[1]; + return envs; + }, {}).SHELL; + if(typeof shell === 'undefined') { shell = 'sh'; } From 3cede9eb748fec69999af27246af3402db5eeab0 Mon Sep 17 00:00:00 2001 From: TeckniX Date: Fri, 5 Jun 2015 11:10:10 -0400 Subject: [PATCH 05/12] Moved Kitematic dir to Documents Signed-off-by: TeckniX --- src/components/ContainerHomeFolders.react.js | 2 +- src/utils/Util.js | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/components/ContainerHomeFolders.react.js b/src/components/ContainerHomeFolders.react.js index 4f769ce766..cc62cd6a87 100644 --- a/src/components/ContainerHomeFolders.react.js +++ b/src/components/ContainerHomeFolders.react.js @@ -25,7 +25,7 @@ var ContainerHomeFolder = React.createClass({ }, (index) => { if (index === 0) { var volumes = _.clone(this.props.container.Volumes); - var newHostVolume = path.join(util.home(), 'Kitematic', this.props.container.Name, containerVolume); + var newHostVolume = path.join(util.home(), util.documents(), 'Kitematic', this.props.container.Name, containerVolume); volumes[containerVolume] = newHostVolume; var binds = _.pairs(volumes).map(function (pair) { if(util.isWindows()) { diff --git a/src/utils/Util.js b/src/utils/Util.js index 8d90f74166..60554439ab 100644 --- a/src/utils/Util.js +++ b/src/utils/Util.js @@ -39,6 +39,9 @@ module.exports = { home: function () { return process.env[this.isWindows() ? 'USERPROFILE' : 'HOME']; }, + documents: function () { + return this.isWindows() ? 'My\ Documents' : 'Documents'; + }, supportDir: function () { var dirs = ['Library', 'Application\ Support', 'Kitematic']; var acc = this.home(); From 4b708f2275ad48ed17c6d5c26e1a406fdfe0f07f Mon Sep 17 00:00:00 2001 From: Vojta Bartos Date: Fri, 5 Jun 2015 19:49:18 +0200 Subject: [PATCH 06/12] Making condition simple - removed checking for undefined, not necessary --- src/components/ContainerDetailsSubheader.react.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/ContainerDetailsSubheader.react.js b/src/components/ContainerDetailsSubheader.react.js index c34ccd6de8..72f2f9d1aa 100644 --- a/src/components/ContainerDetailsSubheader.react.js +++ b/src/components/ContainerDetailsSubheader.react.js @@ -107,7 +107,7 @@ var ContainerDetailsSubheader = React.createClass({ return envs; }, {}).SHELL; - if(typeof shell === 'undefined') { + if(!shell) { shell = 'sh'; } machine.ip().then(ip => { From 577858f9a1d6a636dba97816b171cfbce8a6af87 Mon Sep 17 00:00:00 2001 From: Jeffrey Morgan Date: Fri, 5 Jun 2015 10:56:38 -0700 Subject: [PATCH 07/12] Fixed docs to no longer mention copying binaries --- docs/index.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/docs/index.md b/docs/index.md index 0ddfc9f3b9..60a58533b2 100755 --- a/docs/index.md +++ b/docs/index.md @@ -28,10 +28,9 @@ container! ## Technical Details -Kitematic is a self-contained .app, with a two exceptions: +Kitematic is a self-contained .app, with an exception: - It will install VirtualBox if it's not already installed. -- It copies the `docker` and `docker-machine` binaries to `/usr/local/bin` for convenience. ### Why does Kitematic need my root password? From bf7d3af40229472d2f98178f3eeae56127e9f6c4 Mon Sep 17 00:00:00 2001 From: Jeffrey Morgan Date: Fri, 5 Jun 2015 21:22:34 -0700 Subject: [PATCH 08/12] Fixed bug with API requests to 1.7 RC2 /containers/create endpoint --- src/utils/DockerUtil.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/utils/DockerUtil.js b/src/utils/DockerUtil.js index 1109a381d1..a3b2424985 100644 --- a/src/utils/DockerUtil.js +++ b/src/utils/DockerUtil.js @@ -103,6 +103,8 @@ export default { containerData.Env = containerData.Config.Env; } + containerData.Volumes = _.mapObject(containerData.Volumes, () => {return {};}); + let existing = this.client.getContainer(name); existing.kill(() => { existing.remove(() => { @@ -203,7 +205,6 @@ export default { containerServerActions.error({name, error}); return; } - existingData.name = existingData.Name || name; if (existingData.Config && existingData.Config.Image) { existingData.Image = existingData.Config.Image; @@ -371,6 +372,7 @@ export default { // data is associated with one layer only (can be identified with id) stream.on('data', str => { + console.log(str); var data = JSON.parse(str); if (data.error) { From cc0bc719fa15cb1adfe8edeed880d2f204516be4 Mon Sep 17 00:00:00 2001 From: Jeffrey Morgan Date: Fri, 5 Jun 2015 21:23:14 -0700 Subject: [PATCH 09/12] Removing unnecessary print statement --- src/utils/DockerUtil.js | 1 - 1 file changed, 1 deletion(-) diff --git a/src/utils/DockerUtil.js b/src/utils/DockerUtil.js index a3b2424985..46dceeb5a1 100644 --- a/src/utils/DockerUtil.js +++ b/src/utils/DockerUtil.js @@ -372,7 +372,6 @@ export default { // data is associated with one layer only (can be identified with id) stream.on('data', str => { - console.log(str); var data = JSON.parse(str); if (data.error) { From 72d4e21a34aeb53216308d6e4868dae96c46733e Mon Sep 17 00:00:00 2001 From: Jeffrey Morgan Date: Fri, 5 Jun 2015 21:34:44 -0700 Subject: [PATCH 10/12] Fixed bug where packaging binaries would fail on release --- gulpfile.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gulpfile.js b/gulpfile.js index 09b70a92b9..6099fb736b 100644 --- a/gulpfile.js +++ b/gulpfile.js @@ -207,7 +207,7 @@ gulp.task('download-docker', function (cb) { } else { request('https://get.docker.com/builds/Darwin/x86_64/docker-' + packagejson['docker-version']) .pipe(fs.createWriteStream('./resources/docker')).on('finish', function () { - fs.chmodSync('./resources/docker', 755); + fs.chmodSync('./resources/docker', 0755); cb(); }); } @@ -230,7 +230,7 @@ gulp.task('download-docker-machine', function (cb) { } else { request('https://github.com/docker/machine/releases/download/v' + packagejson['docker-machine-version'] + '/docker-machine_darwin-amd64') .pipe(fs.createWriteStream('./resources/docker-machine')).on('finish', function () { - fs.chmodSync('./resources/docker-machine', 755); + fs.chmodSync('./resources/docker-machine', 0755); cb(); }); } @@ -252,7 +252,7 @@ gulp.task('download-docker-compose', function (cb) { gutil.log(gutil.colors.green('Downloading Docker Compose')); request('https://github.com/docker/compose/releases/download/' + packagejson['docker-compose-version'] + '/docker-compose-Darwin-x86_64') .pipe(fs.createWriteStream('./resources/docker-compose')).on('finish', function () { - fs.chmodSync('./resources/docker-compose', 755); + fs.chmodSync('./resources/docker-compose', 0755); cb(); }); } From 95993a7ffbb26edec3456655aaf4667990eb9e84 Mon Sep 17 00:00:00 2001 From: Jeffrey Morgan Date: Mon, 8 Jun 2015 13:04:31 -0700 Subject: [PATCH 11/12] Fixed bug where error would not show if fetching recommended repos failed --- src/utils/RegHubUtil.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/utils/RegHubUtil.js b/src/utils/RegHubUtil.js index 8bad189107..cf00640249 100644 --- a/src/utils/RegHubUtil.js +++ b/src/utils/RegHubUtil.js @@ -56,7 +56,7 @@ module.exports = { recommended: function () { request.get('https://kitematic.com/recommended.json', (error, response, body) => { if (error) { - repositoryServerActions.recommendedError({error}); + repositoryServerActions.error({error}); } let data = JSON.parse(body); From 05e32dc3e584afe4a6b491298c892a68b2538422 Mon Sep 17 00:00:00 2001 From: Jeffrey Morgan Date: Tue, 9 Jun 2015 17:57:17 -0700 Subject: [PATCH 12/12] Bump machine version to 0.3.0 rc2 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index f33814e197..88516fdf8d 100644 --- a/package.json +++ b/package.json @@ -26,7 +26,7 @@ } ], "docker-version": "1.6.2", - "docker-machine-version": "0.3.0-rc1", + "docker-machine-version": "0.3.0-rc2", "docker-compose-version": "1.2.0", "electron-version": "0.27.2", "virtualbox-version": "4.3.28",