Giter Club home page Giter Club logo

dockly's Introduction



Immersive terminal interface for managing docker containers, services and images

Node Version view on npm view on npm npm module downloads Security Responsible Disclosure dockly

Dockly has been highlighted, featured and chosen as favorite docker container management tool on:

Awesome Docker DevOps Weekly terminals are sexy Programmer's Weekly Console.dev

Console - Developer Tool of the Week

dockly-demo-2

Install

Install the API module as a dependency in your project so you can easily use it to query Operations Orchestration REST API

npm install -g dockly

Usage

Just fire up dockly and it will automatically connect to your localhost docker daemon through the unix socket:

dockly

Command line options:

It's also possible to provide command line options for dockly to customize the docker connection

Param Type Description
-s or --socketPath string Docker socket to connect to
-H or --host string Remote docker daemon host to connect to
-P or --port string Remote docker port to connect to
-T or --protocol http | https | ssh Remote docker protocol to connect to
--containerFilters string String to apply to filter shown containers
-h or --help null Display help
-v or --version null Display version information

--containerFilters

This is a string that could be used to filter the shown containers; its format is in the x-www-form-urlencoded style and the filters you could apply are listed here: https://docs.docker.com/engine/api/v1.37/#operation/ContainerList

Example: --containerFilters="name=test&status=running" to only show running container which name match test.

Docker Support

Run from docker

You can run dockly using docker:

docker run -it --rm -v /var/run/docker.sock:/var/run/docker.sock lirantal/dockly

Build

If you wish to build dockly as a docker image yourself, you can run the following:

$ docker build -t dockly .

$ docker run -it --rm --name dockly -v /var/run/docker.sock:/var/run/docker.sock dockly

FAQ

  1. Unsupported Node.js version

If you're getting the following error in your CLI:

root@neo:~# dockly
/usr/local/lib/node_modules/dockly/src/screen.js:36
constructor (utils = new Map()) {
^

SyntaxError: Unexpected token =
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:374:25)

Or this kind of error:

Trace: TypeError: Object.values is not a function                                                                                                            
    at screen.toggleMode (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/src/screen.js:149:35)
    at Screen.screen.key (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/src/screen.js:190:12)
    at Screen.EventEmitter._emit
    (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/node_modules/blessed/lib/events.js:98:20)

This is most likely because you're using an unsupported Node.js version. Dockly requires Node.js v7.6 and above

  1. PuTTY displays garbled text

Follow the steps in this comment to enable VT100 support on the settings for the window

  1. Icons not working properly

set LANG and LC_ALL to c.UTF-8 like so

export LANG=C.UTF-8
export LC_ALL=C.UTF-8

for more info please see this issue

Alternatives

See Awesome Docker list for similar tools to work with Docker.

In the news

Author

Liran Tal [email protected]

dockly's People

Contributors

akdm avatar art1415926535 avatar bieron avatar danielruf avatar hoegge avatar hydrosquall avatar israelroldan avatar jamesking56 avatar jimcodified avatar kadenlnelson avatar kopiro avatar lawrenceb5477 avatar lirantal avatar matanavneri avatar norweeg avatar omribarzik avatar robhowell avatar saemik94 avatar snyk-bot avatar sootysec avatar stokito avatar styfle avatar trevdor avatar triforcely avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

dockly's Issues

Refactor dockerUtil for class-based code style

src/dockerUtil.js currently uses JavaScript prototype based definitions to define the object instance. Desired state will be to refactor it for new ES6 class style to be in-par with the rest of the code.

Shell launches xcode editor w dockerRunScript.sh

Expected Behavior

Actual shell launches

Actual Behavior

Xcode pops up with the run script code in it instead of executing
image

Steps to Re-produce the Problem

  1. Load dockly

  2. Choose container

  3. Run shell command

Context

  • Operating System: Mac High Sierra
  • Node.js version (run node --version): v8.9.3
  • Package version: [email protected]
  • Docker version (run docker --version): Docker version 18.06.1-ce, build e68fc7a
  • Is docker installed locally? Yes
  • Do you have containers created? Yes
  • Does this file exists /var/run/docker.sock ? Yes
  • Output of docker info:
Containers: 30
 Running: 28
 Paused: 0
 Stopped: 2
Images: 33
Server Version: 18.06.1-ce
Storage Driver: overlay2
 Backing Filesystem: extfs
 Supports d_type: true
 Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host ipvlan macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 468a545b9edcd5932818eb9de8e72413e616e86e
runc version: 69663f0bd4b60df09991c08812a60108003fa340
init version: fec3683
Security Options:
 seccomp
  Profile: default
Kernel Version: 4.9.93-linuxkit-aufs
Operating System: Docker for Mac
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 1.952GiB
Name: linuxkit-025000000001
ID: SRTA:C3MC:5ZBY:ZMKQ:4YZV:DMKZ:5YWF:2X2B:FOOQ:R57F:QSNV:ZAVT
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): true
 File Descriptors: 249
 Goroutines: 226
 System Time: 2018-09-18T15:53:42.2246559Z
 EventsListeners: 2
HTTP Proxy: gateway.docker.internal:3128
HTTPS Proxy: gateway.docker.internal:3129
Registry: https://index.docker.io/v1/
Labels:
Experimental: true
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false

Todo List

Next milestone:

  • Honor the DOCKER_HOST env variable to connect to a specific docker server
  • Searchable containers
  • Show overall containers cpu/memory (dashboard style)
  • Open container/images menu for general commands: remove container/all containers/completely, cleanup images and containers, etc
  • Live logs search for specific string

Refactoring milestone:

  • ES6
  • Standardjs
  • Move to Yarn
  • Move to classes for widgets
  • Provide framework on-top of blessed for managing widgets (events, init, etc)

Dockly via docker, hide itself

Expected Behavior

If I run Dockly via Docker, it should not show itself in the running containers list.

Actual Behavior

It appears in the running containers list.

Steps to Re-produce the Problem

  1. Launch Dockly via Docker

  2. Check the list to see if it includes Dockly.

Context

  • Operating System: Ubuntu 16.04.5 LTS
  • Node.js version (run node --version): v8.15.0
  • Package version: Latest, as its pulled via Docker
  • Docker version (run docker --version): 18.09.0, build 4d60db4
  • Is docker installed locally? Yes
  • Do you have containers created? Yes
  • Does this file exists /var/run/docker.sock ? Yes
  • Output of docker info:
Containers: 3
 Running: 3
 Paused: 0
 Stopped: 0
Images: 15
Server Version: 18.09.0
Storage Driver: overlay2
 Backing Filesystem: extfs
 Supports d_type: true
 Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: c4446665cb9c30056f4998ed953e6d4ff22c7c39
runc version: 4fc53a81fb7c994640722ac585fa9ca548971871
init version: fec3683
Security Options:
 apparmor
 seccomp
  Profile: default
Kernel Version: 4.4.0-141-generic
Operating System: Ubuntu 16.04.5 LTS
OSType: linux
Architecture: x86_64
CPUs: 8
Total Memory: 15.63GiB
Name: wp-096-du
ID: UCMJ:G67O:OES4:Y72N:C34V:NDNC:JAX6:WQKE:CUZE:XL6F:NXOA:S7ID
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Username: jamesking56
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false
Product License: Community Engine

WARNING: No swap limit support

Error when container not running?

I tried running dockly and received the following error. After running a container (redis) dockly seem to work just fine.

Error: Unable to determine the domain name
-> check your connection options to the docker daemon and confirm containers exist

Images information

Hi Liran,

Your tool looks and works amazing!

Can I request one more feature, which will be very cool to have there?
Feature: Get the information about images on a host.
We can see the actual running containers, but no info about images.

Kind Regards,
CrDemon

Scroll through logs?

Hi, this tool is already so great. Thanks for your hard work!

This may already be possible so please feel free to close if so. Is it possible to scroll through the entire logs for a container? The view window is rather small and seems to be truncated by default which makes sense for the dashboard. However, having an option to view the full logs somehow would make this my number 1 docker tool.

We could have a button at the bottom that opens the full logs in a model similar to info. Maybe it happens automatically if you press return twice quickly?

log widget concatenates logs to screen on every '[return]' keypress

Expected Behavior

When I want to select a container to view logs, I would expect that everytime I press [return], the logs would refresh on the screen and not continuously be appended to the widget on every keypress

Actual Behavior

https://gyazo.com/94176c93f28bd37c65c26ba0a0a1ef9e, in this gif I'm opening dockly using the cli dockly and continuously pressing [return] to get the container's logs.

Steps to Re-produce the Problem

  1. See above

Context

  • Operating System: OS X 10.14.2
  • Node.js version (run node --version): v8.11.4
  • Package version: dockly 3.8.1 by Liran Tal<[email protected]>
  • Docker version (run docker --version): Docker version 18.09.0, build 4d60db4
  • Is docker installed locally? I believe so
  • Do you have containers created? yes, 1 nginx container running, with a sample get request in logs
  • Does this file exists /var/run/docker.sock ? yes
  • Output of docker info:
Containers: 1
 Running: 1
 Paused: 0
 Stopped: 0
Images: 954
Server Version: 18.09.0
Storage Driver: overlay2
 Backing Filesystem: extfs
 Supports d_type: true
 Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host ipvlan macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: active
 NodeID: ugn7xu2h9qb81dcxp8zm83hzg
 Is Manager: true
 ClusterID: i0a00s1yr5bde7ko2ddx9tlhm
 Managers: 1
 Nodes: 1
 Default Address Pool: 10.0.0.0/8  
 SubnetSize: 24
 Orchestration:
  Task History Retention Limit: 5
 Raft:
  Snapshot Interval: 10000
  Number of Old Snapshots to Retain: 0
  Heartbeat Tick: 1
  Election Tick: 10
 Dispatcher:
  Heartbeat Period: 5 seconds
 CA Configuration:
  Expiry Duration: 3 months
  Force Rotate: 0
 Autolock Managers: false
 Root Rotation In Progress: false
 Node Address: 192.168.65.3
 Manager Addresses:
  192.168.65.3:2377
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 468a545b9edcd5932818eb9de8e72413e616e86e
runc version: 69663f0bd4b60df09991c08812a60108003fa340
init version: fec3683
Security Options:
 seccomp
  Profile: default
Kernel Version: 4.9.125-linuxkit
Operating System: Docker for Mac
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 3.855GiB
Name: linuxkit-025000000001
ID: CZFX:2NBQ:6FL2:OEDX:LS2X:XDGX:BWAT:ODLC:6ATS:UE4S:VUQ5:OO3Y
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): true
 File Descriptors: 140
 Goroutines: 270
 System Time: 2019-01-14T15:03:37.0602015Z
 EventsListeners: 2
HTTP Proxy: gateway.docker.internal:3128
HTTPS Proxy: gateway.docker.internal:3129
Registry: https://index.docker.io/v1/
Labels:
Experimental: true
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false
Product License: Community Engine

The actions menu display/hide isn't consistent

Expected Behavior

Toggling on/off the actions menu with the m key should work as expected.

Actual Behavior

When toggling the menu to display, and then hiding it with esc key, clicking again the m key to display it doesn't work.

Security issues due to deps

Expected Behavior

No security vulnerabilities introduced through libraries

Actual Behavior

Snyk test reports:

~/projects/repos/dockly ๎‚ฐ ๎‚  master โ— โŸ2 ๎‚ฐ snyk test                                                                                                                                                                                              ๎‚ฒ 10.13.0 โฌข ๎‚ฒ 6972 ๎‚ฒ 11:31:07

Testing /Users/lirantal/projects/repos/dockly...

โœ— Low severity vulnerability found in lodash
  Description: Prototype Pollution
  Info: https://snyk.io/vuln/SNYK-JS-LODASH-73638
  Introduced through: [email protected]
  From: [email protected] > [email protected]

โœ— Medium severity vulnerability found in lodash
  Description: Regular Expression Denial of Service (ReDoS)
  Info: https://snyk.io/vuln/SNYK-JS-LODASH-73639
  Introduced through: [email protected]
  From: [email protected] > [email protected]




Organisation:      snyk-demo-567
Package manager:   yarn
Target file:       yarn.lock
Open source:       no
Project path:      /Users/lirantal/projects/repos/dockly

Tested 114 dependencies for known vulnerabilities, found 2 vulnerabilities, 2 vulnerable paths.

Run `snyk wizard` to address these issues.

Steps to Re-produce the Problem

  1. Install snyk
  2. Run snyk test

Container Permissions

Expected Behavior

A logged in system user should only be able to delete/restart/stop containers that they create

Actual Behavior

A logged in system user who executes dockly can delete ANY container

Steps to Re-produce the Problem

  1. Create a docker container

  2. Change user and run dockly

  3. Delete the previous users container!

Context

  • Operating System: Ubuntu 18.04 LTS
  • Node.js version (run node --version): v8.10.0
  • Package version: 3.10.5
  • Docker version (run docker --version): 18.09.4, build d14af54266
  • Is docker installed locally? Yes
  • Do you have containers created? Yes
  • Does this file exists /var/run/docker.sock ? Yes
  • Output of docker info:

Containers: 2
Running: 2
Paused: 0
Stopped: 0
Images: 2
Server Version: 18.09.4
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge host macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: active
NodeID: rx0gc7skzjhuelaokwnpg046n
Is Manager: true
ClusterID: y6nsgp3syry2yfzmltb2oth6r
Managers: 1
Nodes: 2
Default Address Pool: 10.0.0.0/8
SubnetSize: 24
Orchestration:
Task History Retention Limit: 5
Raft:
Snapshot Interval: 10000
Number of Old Snapshots to Retain: 0
Heartbeat Tick: 1
Election Tick: 10
Dispatcher:
Heartbeat Period: 5 seconds
CA Configuration:
Expiry Duration: 3 months
Force Rotate: 0
Autolock Managers: false
Root Rotation In Progress: false
Node Address: 10.108.150.11
Manager Addresses:
10.108.150.11:2377
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: bb71b10fd8f58240ca47fbb579b9d1028eea7c84
runc version: 2b18fe1d885ee5083ef9f0838fee39b62d653e30
init version: fec3683
Security Options:
apparmor
seccomp
Profile: default
Kernel Version: 4.15.0-47-generic
Operating System: Ubuntu 18.04.1 LTS
OSType: linux
Architecture: x86_64
CPUs: 24
Total Memory: 125.9GiB
Name: docker01
ID: HKRG:4J4I:T4F2:4GOB:3IZQ:AOMZ:O7VH:G3J4:IFTD:KP2P:O43T:REN5
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
Product License: Community Engine

WARNING: No swap limit support

App just crashes

Hi there. When i'm opening dockly, i'm just getting this:

Trace: Error: Cannot read property 'length' of null
at exitError (/usr/lib/node_modules/dockly/index.js:69:13)
at process.on (/usr/lib/node_modules/dockly/index.js:17:7)
at emitOne (events.js:101:20)
at process.emit (events.js:188:7)
at process._fatalException (bootstrap_node.js:296:26)

Dockly via Docker, container left behind

Expected Behavior

When running dockly via Docker and pressing q to quit, the dockly container should no longer exist.

Actual Behavior

The container is left behind.

Steps to Re-produce the Problem

  1. Launch dockly via Docker

  2. Press q to quit

  3. Do docker container ls -a and see dockly still exists as a container

Context

  • Operating System: Ubuntu 16.04.5 LTS
  • Node.js version (run node --version): v8.15.0
  • Package version: Latest, as its pulled via Docker
  • Docker version (run docker --version): 18.09.0, build 4d60db4
  • Is docker installed locally? Yes
  • Do you have containers created? Yes
  • Does this file exists /var/run/docker.sock ? Yes
  • Output of docker info:
Containers: 3
 Running: 3
 Paused: 0
 Stopped: 0
Images: 15
Server Version: 18.09.0
Storage Driver: overlay2
 Backing Filesystem: extfs
 Supports d_type: true
 Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: c4446665cb9c30056f4998ed953e6d4ff22c7c39
runc version: 4fc53a81fb7c994640722ac585fa9ca548971871
init version: fec3683
Security Options:
 apparmor
 seccomp
  Profile: default
Kernel Version: 4.4.0-141-generic
Operating System: Ubuntu 16.04.5 LTS
OSType: linux
Architecture: x86_64
CPUs: 8
Total Memory: 15.63GiB
Name: wp-096-du
ID: UCMJ:G67O:OES4:Y72N:C34V:NDNC:JAX6:WQKE:CUZE:XL6F:NXOA:S7ID
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Username: jamesking56
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false
Product License: Community Engine

WARNING: No swap limit support

Extra blank lines in log output

Expected Behavior

have the logs to appear contiguously

โ”Œโ”€Container Logsโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚2018-08-31T17:02:46.143404367Z   ActiveSupport::Cache::RedisStore  ..............   debug  +A  -T                                                                                       โ”‚
โ”‚2018-08-31T17:02:46.143409468Z   ActiveSupport::Dependencies  ...................   debug  +A  -T                                                                                       โ”‚
โ”‚2018-08-31T17:02:46.143413998Z   Logging  .......................................    *off  -A  -T                                                                                       โ”‚
โ”‚2018-08-31T17:02:46.143418378Z   Rails  .........................................   debug  +A  -T                                                                                       โ”‚
โ”‚2018-08-31T17:02:46.520225729Z [1] Puma starting in cluster mode...                                                                                                                     โ”‚
โ”‚2018-08-31T17:02:46.520256725Z [1] * Version 3.12.0 (ruby 2.5.1-p57), codename: Llamas in Pajamas                                                                                       โ”‚
โ”‚2018-08-31T17:02:46.520262533Z [1] * Min threads: 5, max threads: 5                                                                                                                     โ”‚
โ”‚2018-08-31T17:02:46.520267109Z [1] * Environment: development                                                                                                                           โ”‚
โ”‚2018-08-31T17:02:46.520271401Z [1] * Process workers: 2                                                                                                                                 โ”‚
โ”‚2018-08-31T17:02:46.520275520Z [1] * Preloading application                                                                                                                             โ”‚
โ”‚2018-08-31T17:02:46.522058343Z [1] * Listening on tcp://0.0.0.0:3000                                                                                                                    โ”‚
โ”‚2018-08-31T17:02:46.522088104Z [1] Use Ctrl-C to stop                                                                                                                                   โ”‚
โ”‚2018-08-31T17:02:46.531229046Z [1] - Worker 0 (pid: 13) booted, phase: 0                                                                                                                โ”‚
โ”‚2018-08-31T17:02:46.537430501Z [1] - Worker 1 (pid: 26) booted, phase: 0                                                                                                                โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Actual Behavior

there are extra blank lines in the logs

โ”Œโ”€Container Logsโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚2018-08-31T17:02:46.143404367Z   ActiveSupport::Cache::RedisStore  ..............   debug  +A  -T                                                                                       โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.143409468Z   ActiveSupport::Dependencies  ...................   debug  +A  -T                                                                                       โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.143413998Z   Logging  .......................................    *off  -A  -T                                                                                       โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.143418378Z   Rails  .........................................   debug  +A  -T                                                                                       โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.520225729Z [1] Puma starting in cluster mode...                                                                                                                     โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.520256725Z [1] * Version 3.12.0 (ruby 2.5.1-p57), codename: Llamas in Pajamas                                                                                       โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.520262533Z [1] * Min threads: 5, max threads: 5                                                                                                                     โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.520267109Z [1] * Environment: development                                                                                                                           โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.520271401Z [1] * Process workers: 2                                                                                                                                 โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.520275520Z [1] * Preloading application                                                                                                                             โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.522058343Z [1] * Listening on tcp://0.0.0.0:3000                                                                                                                    โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.522088104Z [1] Use Ctrl-C to stop                                                                                                                                   โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.531229046Z [1] - Worker 0 (pid: 13) booted, phase: 0                                                                                                                โ”‚
โ”‚                                                                                                                                                                                        โ”‚
โ”‚2018-08-31T17:02:46.537430501Z [1] - Worker 1 (pid: 26) booted, phase: 0                                                                                                                โ”‚
โ”‚                                                                                                                                                                                       |โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Steps to Re-produce the Problem

  1. Select a docker container
  2. press Return to show its logs

Context

  • Operating System: Arch Linux

  • Node.js version (run node --version): v10.4.0

  • Package version: dockly 3.7.0

  • Docker version (run docker --version): Docker version 18.05.0-ce, build f150324782

  • Terminal version: GNOME Terminal 3.24.1 Using VTE version 0.52.2 +GNUTLS

  • Is docker installed locally? yes

  • Do you have containers created? yes

  • Does this file exists /var/run/docker.sock ? yes

  • Output of docker info: (not relevant to the issue)

[Question] Install via apt

On a small VPS that doesn't have anything extra installed, it would be nice to be able to install a packaged version (e.g. apt).

Is this possible?

Pressing `l` to open shell runs `xdg-open` on Linux

Expected Behavior

The script should be spawned.

Actual Behavior

The script is opened with xdg-open on Linux, and the default handler on Mac (XCode, I think). On my computer, xdg-open ends up trying to open the script in Chromium, which then tries to download the script.

Related issues: #76, #55, possibly #65.

Rather than using open here, I believe child_process.spawn would work. opn calls open on Darwin, xdg-open if it's available, and whatever the Windows equivalent is on Windows. For a shell script, that could be anything from an IDE to spawning a terminal that runs Vim to not even having a good default (like on my machine).

Using child_process.spawn would mean running in the same window rather than trying to open a new terminal. child_process.exec could be used to open a new terminal, but would require a good bit of logic (check platform, try to figure out the correct terminal, etc).

Steps to Re-produce the Problem

  1. Run Dockly on Linux without setting a handler for shell files
  2. Try to launch a shell through Dockly

Context

  • Operating System:
  • Node.js version (run node --version): 10.12.0
  • Package version: 3.8.0
  • Docker version (run docker --version): 10.06.1-ce
  • Is docker installed locally? Yes
  • Do you have containers created? Yes
  • Does this file exists /var/run/docker.sock ? Yes
  • Output of docker info: Not relevant

Error on startup on a Mac

Expected Behavior

"UI" comes up

Actual Behavior

HTML error page is displayed

Steps to Re-produce the Problem

$ docker-machine env
export DOCKER_TLS_VERIFY="1"
export DOCKER_HOST="tcp://...:2376"
export DOCKER_CERT_PATH="/Users/.../.docker/machine/machines/default"
export DOCKER_MACHINE_NAME="default"
$ npm install -g dockly
...
$ dockly
Usage: dockly [OPTIONS]
...
Trace: { Error: (HTTP code 503) unexpected - <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 
...
			<div id="main">
				<h1>Websites are turned off.</h1>
				<h2>An administrator can turn them on using the Server application.</h2>
			</div>
...
    at /Users/mu/.nodenv/versions/8.2.1/lib/node_modules/dockly/node_modules/docker-modem/lib/modem.js:254:17
    at getCause (/Users/mu/.nodenv/versions/8.2.1/lib/node_modules/dockly/node_modules/docker-modem/lib/modem.js:284:7)
    at Modem.buildPayload (/Users/mu/.nodenv/versions/8.2.1/lib/node_modules/dockly/node_modules/docker-modem/lib/modem.js:253:5)
    at IncomingMessage.<anonymous> (/Users/mu/.nodenv/versions/8.2.1/lib/node_modules/dockly/node_modules/docker-modem/lib/modem.js:229:14)
    at emitNone (events.js:110:20)
    at IncomingMessage.emit (events.js:207:7)
    at endReadableNT (_stream_readable.js:1045:12)
    at _combinedTickCallback (internal/process/next_tick.js:138:11)
    at process._tickCallback (internal/process/next_tick.js:180:9)
  reason: undefined,
  statusCode: 503,
  json: '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"\n\t"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">\n\n<html xmlns="http://www.w3.org/1999/xhtml" lang="en">\n\t<head>\n\t\t<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />\n\t\t<title>Server</title>\n\t\t<style type="text/css">\n\t\t* {\t\t\n\t\t\t-webkit-box-sizing: border-box;\n\t\t\t-moz-box-sizing: border-box;\n\t\t\t-box-sizing: border-box;\n\t\t}\n\t\tbody, html {\n\t\t\tbackground-color: #F2F3F4;\n\t\t\tcolor: #333333;\n\t\t\tfont-family: \'Lucida Grande\', \'Lucida Sans Unicode\', Helvetica, Arial, Verdana, sans-serif;\n\t\t\tfont-size: 14px;\n\t\t\theight: 100%;\n\t\t\tline-height: 21px;\n\t\t\tmargin: 0px;\n\t\t\ttext-align: center;\n\t\t\tword-spacing: -1px;\n\t\t}\n\t\t#content {\n\t\t\tpadding: 26px;\n\t\t}\n\t\t#main {\n\t\t\tbackground: #FFFFFF;\n\t\t\tborder: 1px solid #D5D5D6;\n\t\t\tborder-top-color: #E0E1E2;\n\t\t\tborder-bottom-color: #C0C1C2;\n\t\t\tmargin: 0px auto 0px auto;\n\t\t\tpadding: 100px 0px 100px 0px;\n\t\t\twidth: 730px;\n\t\t\t-webkit-box-shadow: 0px 1px 3px rgba(0,0,0,0.1);\n\t\t\t-moz-box-shadow: 0px 1px 3px rgba(0,0,0,0.1);\n\t\t\tbox-shadow: 0px 1px 3px rgba(0,0,0,0.1);\n\t\t\t-webkit-border-radius: 6px;\n\t\t\t-moz-border-radius: 6px;\n\t\t\tborder-radius: 6px;\n\t\t}\n\t\th1, h2 {\n\t\t\tcolor: #BBBBBB;\n\t\t\tfont-family: Helvetica, Arial, Verdana, sans-serif;\n\t\t\tfont-size: 18px;\n\t\t\tfont-weight: normal;\n\t\t\tline-height: 25px;\n\t\t\tmargin: 0px;\n\t\t\ttext-align: center;\n\t\t}\n\t\t</style>\n\t</head>\n\t<body>\n\t\t<div id="content">\n\t\t\t<div id="main">\n\t\t\t\t<h1>Websites are turned off.</h1>\n\t\t\t\t<h2>An administrator can turn them on using the Server application.</h2>\n\t\t\t</div>\n\t\t</div>\n\t</body>\n</html>\n' }
    at exitError (/Users/mu/.nodenv/versions/8.2.1/lib/node_modules/dockly/index.js:68:13)
    at initDockerConnection.then.then.catch (/Users/mu/.nodenv/versions/8.2.1/lib/node_modules/dockly/index.js:21:12)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:188:7)

Context

  • Operating System: macOS high sierra
  • Node.js version: 8.2.1
  • Package version: latest (--version doesn't work either)
  • Docker version: 17.09.0-ce
  • Is docker installed locally? docker-machine with fusion driver
  • Do you have containers created? yes
  • Does this file exists /var/run/docker.sock ? no (see output of docker-machine env above)

Toggle view mode button is missing on services view

Expected Behavior

When I am toggling the view mode to the 'services' view I don't see the same bottom menu button (to help me know how to toggle view mode again)

Actual Behavior

Toggle view mode is a primary button on all screens

Steps to Re-produce the Problem

  1. Run dockly

  2. Toggle the view mode for the services view

  3. No 'toggle view' mode menu item

image

Feature request: start shell in same terminal window

Right now when starting a shell for a docker container, the dockerRunScript.sh is launched in a new tab/window. Is it possible to have this script open in the same window (possibly integrated within the Dockly interface)? If you could give me some pointers on how to do this, I'll be more than happy to make a pull request.

Better handling for modal windows / child windows - layer manager?

This is more like an invitation to the discussion about the architecture of dockly than bug report at this point

Expected Behavior

You shouldn't be able to lose focus from the active dialog (like m:menu widget). As a contributor, I would like to define correct way of handling this problem in the future.

Actual Behavior

You can permanently lose focus when the tab is pressed while 'm'enu is open. There is no easy way of implementing "windows" displayed on top of the current screen.

What (I believe) is needed

Currently when we want to display something on top of current screen, widget is simply appended to the grid with layout settings. This looks fine but widgets "under" dialog can still be focused and they will receive events unless they are explicitly cancelled.

It would be nice to have some kind of layer system, where whenever dialog/window (like previously mentioned ones) are needed to be displayed, we could simply specify:

  • widget (content of our window)
  • layout (to position/define size of the window)
  • toolbar items (toolbar would be context sensitive - users would always see available actions and it would be impossible to trigger some action from the window behind active dialog)
    • this improves UX (e.g. when i:info is currently open it doesn't make much sense for /:search to be enabled)
    • helpful for power users (e.g. pressing "md" in a sequence would open the menu, select and confirm "delete container" action)

After that, widget and toolbar will be displayed as a new layer and users will be able to interact only with it (unless it is closed or new modal window is displayed on top of it).


I believe that this could be very helpful for me and other contributors interested in implementing additional functionality or more advanced flows based on windows/pop-ups/dialogs. Such layer manager could nicely isolate the widgets from each-other.

Let me know if you think something like that would be a welcome addition to the project. Maybe my idea is too complicated and I'm missing some obvious solutions to the problem? Let's have a brainstorming session!

Can't exec into container

I'm using dockerised version of dockly, and I have multiple containers running, all of them have both sh and bash installed. Other dockly features work well.

Expected Behavior

A shell inside a container is opened

Actual Behavior

ERROR spawnsync docker ENOENT

Steps to Re-produce the Problem

  1. select a container and press "l"

Context

  • Operating System: ubuntu 16.04
  • Node.js version (run node --version): as in librantal/dockly:latest
  • Package version: as in librantal/dockly:latest
  • Docker version (run docker --version): Docker version 18.09.4, build d14af54
  • Is docker installed locally? yes
  • Do you have containers created? yes
  • Does this file exists /var/run/docker.sock ? yes
  • Output of docker info:
Containers: 24
 Running: 24
 Paused: 0
 Stopped: 0
Images: 581
Server Version: 18.09.4
Storage Driver: overlay2
 Backing Filesystem: extfs
 Supports d_type: true
 Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: bb71b10fd8f58240ca47fbb579b9d1028eea7c84
runc version: 2b18fe1d885ee5083ef9f0838fee39b62d653e30
init version: fec3683
Security Options:
 apparmor
 seccomp
  Profile: default
Kernel Version: 4.18.0-041800-lowlatency
Operating System: Ubuntu 16.04.6 LTS
OSType: linux
Architecture: x86_64
CPUs: 8
Total Memory: 15.55GiB
Name: sokrates
ID: 2ZT7:CRKC:PFS2:D4UT:HMGU:5Y4N:YEZK:CDPW:IE7J:RZS7:VYHF:DEGN
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Username: jbieron
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false
Product License: Community Engine

WARNING: No swap limit support

SyntaxError: Use of const in strict mode.

Expected Behavior

It should runs normal.

Actual Behavior

I encountered the SyntaxError: Use of const in strict mode. error and can't solve at my end.

$ dockly

/usr/local/lib/node_modules/dockly/index.js:7
const semver = require('semver')
^^^^^
SyntaxError: Use of const in strict mode.
    at Module._compile (module.js:439:25)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Function.Module.runMain (module.js:497:10)
    at startup (node.js:119:16)
    at node.js:906:3

Steps to Re-produce the Problem

  1. I use my Mac and install dockly via npm
$ sudo npm install -g dockly
  1. Run dockly and shows the error above.

  2. I'm tried install the lack package semver and run again, but not work.

$ sudo npm install -g semver
$ dockly

Context

  • Operating System:
    Mac OS X 10.13.4 (High Sierra)
  • Node.js version (run node --version):
    v0.10.33
  • Package version:
    dockly v3.3.2
  • Docker version (run docker --version):
    Docker version 18.03.0-ce, build 0520e24
  • Is docker installed locally?
    Yes.
  • Do you have containers created?
    Yes.
  • Does this file exists /var/run/docker.sock ?
    Yes.
  • Output of docker info:
Containers: 4
 Running: 2
 Paused: 0
 Stopped: 2
Images: 41
Server Version: 18.03.0-ce
Storage Driver: overlay2
 Backing Filesystem: extfs
 Supports d_type: true
 Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: cfd04396dc68220d1cecbe686a6cc3aa5ce3667c
runc version: 4fc53a81fb7c994640722ac585fa9ca548971871
init version: 949e6fa
Security Options:
 seccomp
  Profile: default
Kernel Version: 4.9.87-linuxkit-aufs
Operating System: Docker for Mac
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 1.952GiB
Name: linuxkit-025000000001
ID: JDUG:AY3N:4CYB:UOUU:O4WA:CVHK:ODWS:FQ6I:3H67:KKH7:ZNBI:7VTD
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
HTTP Proxy: docker.for.mac.http.internal:3128
HTTPS Proxy: docker.for.mac.http.internal:3129
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false

Use 'sh' instead of '/bin/bash'

Expected Behavior

When launching an 'ssh' session (not really ssh but docker exec) via the l key command, I expect a terminal window to open and be inside my container.

Actual Behavior

Alpine containers (but many others too) don't come with /bin/bash but with /bin/sh, and sh is actually more probable to be in the target container than bash. This causes the terminal session to either exit immediately with an error or be closed before the error message can be read by the user.

Steps to Re-produce the Problem

  1. Run an alpine based container: docker run -td alpine sh

  2. Launch dockly

  3. Select the container and press l

Context

  • Operating System: macOS
  • Node.js version (run node --version): v9.3.0
  • Package version: 3.3.2
  • Docker version (run docker --version): 18.03.0-ce, build 0520e24
  • Is docker installed locally? Yes
  • Do you have containers created? Yes
  • Does this file exists /var/run/docker.sock ? Yes
  • Output of docker info: [Not relevant]

Invisible Keys on CMD / Cmder / Powershell - on Windows

Expected Behavior

Show keys

Actual Behavior

image

Steps to Re-produce the Problem

  1. Install dockly

  2. Open Dockly

  3. Missing Keys from Menus

Context

  • Operating System:
  • Node.js version (run node --version): v8.9.4
  • Package version: 3.3.1
  • Docker version (run docker --version): Docker version 18.03.0-ce, build 0520e24
  • Is docker installed locally? Yes
  • Do you have containers created? Yes
  • Does this file exists /var/run/docker.sock ? n/a
  • Output of docker info:

Error: Cannot read property 'length' of undefined

When loading a list of containers that are unreachable, or navigating in the containers list on non-running containers then the widget for reading cpu/memory metrics is trying to access properties of the container but it can't, so dockly quits with:

Error: Cannot read property 'length' of undefined

Control characters when moving mouse in terminal

Expected Behavior

The same like entering the container shell with docker exec -it bash - which is being able to move the mouse over the terminal without outputting strange control characters.

Actual Behavior

Output of strange control characters ;-)

Steps to Re-produce the Problem

  1. use ddev to create a php environment, start it with "ddev start" (but maybe just any container)

  2. open dockly and enter the web container with the "l" key

  3. move the mouse over the console and see strange characters appear (without any typing)

Context

  • Operating System: MacOS
  • Node.js version (run node --version): 10.13.0
  • Package version: 3.11.0
  • Docker version (run docker --version): 18.09.2
  • Is docker installed locally? yes
  • Do you have containers created? yes
  • Does this file exists /var/run/docker.sock ? yes

Ability to read a specific docker-compose file

This is a feature request. I was wondering if we could read a specific docker-compose file so you can manage only the containers defined in that file.

On my local development, I have myriads of containers running but often times I want to inspect or manage only the containers of the specific project I am working on, which has its own docker-compose definition.

Thank you, loved this tool. ๐Ÿ’ฏ

UnhandledPromiseRejectionWarning

Expected Behavior

Presented with Shell when โ€˜lโ€™ is pressed.

Actual Behavior

Error: (node: 21182) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 3): Error: Exited with code 3

Steps to Re-produce the Problem

  1. Select a container

  2. Press โ€˜lโ€™

Context

  • Operating System: VMware Photon OS
  • Node.js version (run node --version): 8.3.0
  • Package version: 3.7.0
  • Docker version (run docker --version): 17.06.0-ce build 02c1d87
  • Is docker installed locally? Yes
  • Do you have containers created? Yes
  • Does this file exists /var/run/docker.sock ? Yes
  • Output of docker info:

Extra green lines

Actual Behavior

I have 5 extra green lines at the bottom of the window.

image

Steps to Re-produce the Problem

  1. Install Dockly.
  2. Run Dockly from cmd.exe.

Context

  • Operating System: Windows 10
  • Node.js version (run node --version): v10.15.2
  • Package version: 3.10.5
  • Docker version (run docker --version): Docker version 18.03.0-ce, build 0520e24302
  • Is docker installed locally? Yes.
  • Does this file exists /var/run/docker.sock ? No.

Update project information on the CLI

Update src/cli.js to display in the help output:

  1. dockly version
  2. project home

All of which can be easily read from the package's own package.json file.
Currently, the showVersion() function isn't used.

Crash: SyntaxError: Unexpected token ...

Expected Behavior

Launching the app

Actual Behavior

dockly 3.2.1
Usage: dockly [OPTIONS]

dockly

Interactive shell for managing Docker containers

Options

-s, --socketPath string Docker daemon socket to connect to
-h, --help Display this usage guide.
-v, --version Display version

Project home: https://github.com/lirantal/dockly

Trace: /usr/local/lib/node_modules/dockly/widgets/toolbar.widget.js:86
...commands,
^^^

SyntaxError: Unexpected token ...
at createScript (vm.js:56:10)
at Object.runInThisContext (vm.js:97:10)
at Module._compile (module.js:542:28)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.require (module.js:497:17)
at require (internal/module.js:20:19)
at glob.sync.forEach (/usr/local/lib/node_modules/dockly/src/assetsLoader.js:30:46)
at exitError (/usr/local/lib/node_modules/dockly/index.js:79:13)
at initDockerConnection.then.then.catch (/usr/local/lib/node_modules/dockly/index.js:32:12)
at process._tickCallback (internal/process/next_tick.js:109:7)

Context

  • Operating System: Ubuntu 16.04
  • Node.js version (run node --version): 6.12.3
  • Package version:
  • Docker version (run docker --version): 17.12.0
  • Is docker installed locally? yes
  • Do you have containers created? yes
  • Does this file exists /var/run/docker.sock ? yes
  • Output of docker info:

Containers: 37
Running: 5
Paused: 0
Stopped: 32
Images: 168
Server Version: 17.12.0-ce
Storage Driver: aufs
Root Dir: /var/lib/docker/aufs
Backing Filesystem: extfs
Dirs: 367
Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge host macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 89623f28b87a6004d4b785663257362d1658a729
runc version: b2567b37d7b75eb4cf325b77297b140ea686ce8f
init version: 949e6fa
Security Options:
apparmor
seccomp
Profile: default
Kernel Version: 4.4.0-112-generic
Operating System: Ubuntu 16.04.3 LTS
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 11.42GiB
Name: T430
ID: Y423:LBP2:OSYM:7QAL:5BUC:LM6Q:5UWE:DDJL:RDRI:GNLB:XK2B:3RMH
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false

Error message on Ubuntu 16.04

Expected Behavior

Dockly should run.

Actual Behavior

root@neo:~# dockly
/usr/local/lib/node_modules/dockly/src/screen.js:36
constructor (utils = new Map()) {
^

SyntaxError: Unexpected token =
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:374:25)
at Object.Module._extensions..js (module.js:417:10)
at Module.load (module.js:344:32)
at Function.Module._load (module.js:301:12)
at Module.require (module.js:354:17)
at require (internal/module.js:12:17)
at Object. (/usr/local/lib/node_modules/dockly/index.js:10:16)
at Module._compile (module.js:410:26)
at Object.Module._extensions..js (module.js:417:10)
root@neo:~# node --version
v4.2.6

Steps to Re-produce the Problem

  1. Install Ubuntu 16.04
  2. Install docker and create some docker containers
  3. Install node, npm & dockly
  4. Run

Context

  • Operating System: Ubuntu
  • Node.js version (run node --version): v4.2.6 (current in Ubuntu 16.04 LTS)
  • Package version: [email protected]
  • Docker version (run docker --version): Docker version 1.13.1, build 092cba3
  • Is docker installed locally? Yes
  • Do you have containers created? Yes
  • Does this file exists /var/run/docker.sock ? /var/run/docker.sock: socket (yes)
  • Output of docker info:
    Containers: 5
    Running: 5
    Paused: 0
    Stopped: 0
    Images: 6
    Server Version: 1.13.1
    Storage Driver: aufs
    Root Dir: /var/lib/docker/aufs
    Backing Filesystem: extfs
    Dirs: 50
    Dirperm1 Supported: true
    Logging Driver: json-file
    Cgroup Driver: cgroupfs
    Plugins:
    Volume: local
    Network: bridge host macvlan null overlay
    Swarm: inactive
    Runtimes: runc
    Default Runtime: runc
    Init Binary: docker-init
    containerd version: (expected: aa8187dbd3b7ad67d8e5e3a15115d3eef43a7ed1)
    runc version: N/A (expected: 9df8b306d01f59d3a8029be411de015b7304dd8f)
    init version: N/A (expected: 949e6facb77383876aeff8a6944dde66b3089574)
    Security Options:
    apparmor
    seccomp
    Profile: default
    Kernel Version: 4.4.0-112-generic
    Operating System: Ubuntu 16.04.3 LTS
    OSType: linux
    Architecture: x86_64
    CPUs: 4
    Total Memory: 31.32 GiB
    Name: neo
    ID: ***
    Docker Root Dir: /var/lib/docker
    Debug Mode (client): false
    Debug Mode (server): false
    Registry: https://index.docker.io/v1/
    WARNING: No swap limit support
    Experimental: false
    Insecure Registries:
    127.0.0.0/8
    Live Restore Enabled: false

Trace: TypeError: Object.values is not a function

Expected Behavior

App won't crash.

Actual Behavior

App crashes

Steps to Re-produce the Problem

  1. Open
  2. Type :v

Context

  • Operating System: Linux Mint
  • Node.js version (run node --version): v6.11.1
  • Package version: 3.2.3
  • Docker version (run docker --version): Docker version 17.05.0-ce, build 89658be
  • Is docker installed locally? yes
  • Do you have containers created? yes
  • Does this file exists /var/run/docker.sock ? yes
  • Output of docker info:
Containers: 56
 Running: 10
 Paused: 0
 Stopped: 46
Images: 313
Server Version: 17.05.0-ce
Storage Driver: aufs
 Root Dir: /media/vokiel/BACKUP/docker/aufs
 Backing Filesystem: extfs
 Dirs: 601
 Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host macvlan null overlay
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 9048e5e50717ea4497b757314bad98ea3763c145
runc version: 9c2d8d184e5da67c95d601382adf14862e4f2228
init version: 949e6fa
Security Options:
 apparmor
 seccomp
  Profile: default
Kernel Version: 4.10.0-42-generic
Operating System: Linux Mint 18.3
OSType: linux
Architecture: x86_64
CPUs: 4
Total Memory: 15.35GiB
Name: vokiel
ID: 2IKV:JXKR:4CEZ:QQFD:LA2X:2WEC:WJTN:BJZZ:MIT3:X6P5:YUCV:EBSY
Docker Root Dir: /media/vokiel/BACKUP/docker
Debug Mode (client): false
Debug Mode (server): false
Username: vokiel
Registry: https://index.docker.io/v1/
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false

WARNING: No swap limit support

Error message

Trace: TypeError: Object.values is not a function                                                                                                                                                                                                                                           
    at screen.toggleMode (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/src/screen.js:149:35)                                                                                                                                                                             
    at Screen.screen.key (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/src/screen.js:190:12)                                                                                                                                                                             
    at Screen.EventEmitter._emit (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/node_modules/blessed/lib/events.js:98:20)                                                                                                                                                 
    at Screen.EventEmitter.emit (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/node_modules/blessed/lib/events.js:114:17)                                                                                                                                                 
    at Program.<anonymous> (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/node_modules/blessed/lib/widgets/screen.js:593:12)                                                                                                                                              
    at emitTwo (events.js:106:13)                                                                                                                                                                                                                                                           
    at Program.emit (events.js:191:7)                                                                                                                                                                                                                                                       
    at /home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/node_modules/blessed/lib/program.js:410:15                                                                                                                                                                           
    at Array.forEach (native)                                                                                                                                                                                                                                                               
    at ReadStream.input.on.input._keypressHandler (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/node_modules/blessed/lib/program.js:408:23)                                                                                                                              
    at exitError (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/index.js:79:13)                                                                                                                                                                                           
    at process.on (/home/vokiel/.nvm/versions/node/v6.11.1/lib/node_modules/dockly/index.js:28:7)                                                                                                                                                                                           
    at emitOne (events.js:101:20)                                                                                                                                                                                                                                                           
    at process.emit (events.js:188:7)                                                                                                                                                                                                                                                       
    at process._fatalException (bootstrap_node.js:296:26)  

Unexpected crash

Expected Behavior

App work properly

Actual Behavior

Crash suddenly with the following error:


Trace: TypeError: Cannot read property 'ApiVersion' of null
    at /usr/local/lib/node_modules/dockly/src/dockerUtil.js:121:33
    at /usr/local/lib/node_modules/dockly/node_modules/dockerode/lib/docker.js:1224:7
    at /usr/local/lib/node_modules/dockly/node_modules/docker-modem/lib/modem.js:262:7
    at getCause (/usr/local/lib/node_modules/dockly/node_modules/docker-modem/lib/modem.js:284:7)
    at Modem.buildPayload (/usr/local/lib/node_modules/dockly/node_modules/docker-modem/lib/modem.js:253:5)
    at IncomingMessage.<anonymous> (/usr/local/lib/node_modules/dockly/node_modules/docker-modem/lib/modem.js:229:14)
    at IncomingMessage.emit (events.js:165:20)
    at endReadableNT (_stream_readable.js:1101:12)
    at process._tickCallback (internal/process/next_tick.js:152:19)
    at exitError (/usr/local/lib/node_modules/dockly/index.js:88:13)
    at process.on (/usr/local/lib/node_modules/dockly/index.js:37:7)
    at process.emit (events.js:165:20)
    at process._fatalException (bootstrap_node.js:431:26)


Steps to Re-produce the Problem

  1. I just run dockly and played while working on the container

Context

  • Operating System: OSX
  • Node.js version (run node --version): v9.5.0
  • Package version: latest
  • Docker version (run docker --version): Docker version 17.12.0-ce, build c97c6d6
  • Is docker installed locally? yes
  • Do you have containers created? yes
  • Does this file exists /var/run/docker.sock ? no
  • Output of docker info:
Containers: 3
 Running: 2
 Paused: 0
 Stopped: 1
Images: 26
Server Version: 17.12.0-ce
Storage Driver: overlay2
 Backing Filesystem: extfs
 Supports d_type: true
 Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host ipvlan macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 89623f28b87a6004d4b785663257362d1658a729
runc version: b2567b37d7b75eb4cf325b77297b140ea686ce8f
init version: 949e6fa
Security Options:
 seccomp
  Profile: default
Kernel Version: 4.9.60-linuxkit-aufs
Operating System: Docker for Mac
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 1.952GiB
Name: linuxkit-025000000001
ID: JLDG:MULK:4AT5:GMXH:TPPM:GZ2Y:BA75:EAAC:NEHR:CEJR:D6VR:MY6F
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): true
 File Descriptors: 45
 Goroutines: 79
 System Time: 2018-02-13T15:00:22.720277167Z
 EventsListeners: 3
HTTP Proxy: docker.for.mac.http.internal:3128
HTTPS Proxy: docker.for.mac.http.internal:3129
Registry: https://index.docker.io/v1/
Labels:
Experimental: true
Insecure Registries:
 docker-cache:5000
 127.0.0.0/8
Registry Mirrors:
 http://docker-cache:5000/
Live Restore Enabled: false


MaxListenersExceededWarning: Possible EventEmitter memory leak detected.

Expected Behavior

No errors are shown.

Actual Behavior

Errors are emitted which messes up the display:

(node:2248) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 key listeners added. Use emitter.setMaxListeners() to increase limit

Steps to Reproduce the Problem

  1. Launch Ubuntu 19.04 Disco Dingo image on AWS

  2. sudo npm -g install dockly

  3. Run dockly

Context

- Operating System: Ubuntu 19.04 Disco Dingo
- Node.js version (run `node --version`): v10.15.2
- Package version: 3.14.4
- Docker version (run `docker --version`): 18.09.7
- Is docker installed locally? Yes
- Do you have containers created? Yes
- Does this file exists `/var/run/docker.sock` ? Yes
- Output of `docker info`:
Containers: 1
 Running: 0
 Paused: 0
 Stopped: 1
Images: 2
Server Version: 18.09.7
Storage Driver: overlay2
 Backing Filesystem: extfs
 Supports d_type: true
 Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: bridge host macvlan null overlay
 Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 
runc version: N/A
init version: v0.18.0 (expected: fec3683b971d9c3ef73f284f176672c44b448662)
Security Options:
 apparmor
 seccomp
  Profile: default
Kernel Version: 5.0.0-1021-aws
Operating System: Ubuntu 19.04
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 459.1MiB
Name: ip-172-31-42-180
ID: 7WHY:VJVB:U7G7:3MTF:I6QS:7746:N5NT:QKQO:FETA:7PYI:I5LU:P6OF
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
 127.0.0.0/8
Live Restore Enabled: false

WARNING: No swap limit support

Dockerfile is not idempotent and doesn't match the source

It installs dockly via npm here

RUN npm install -g dockly

But really shouldn't it use the dockly that's packaged in the source along with the Dockerfile? So when you build using a CI the source for the docker matches source in your repository, not some random npm version depending on what was pushed for the day.

pull access denied for dockly, repository does not exist or may require 'docker login'.

Following the docs to run dockly:

docker run -it --name dockly -v /var/run/docker.sock:/var/run/docker.sock dockly
Unable to find image 'dockly:latest' locally
docker: Error response from daemon: pull access denied for dockly, repository does not exist or may require 'docker login'.
See 'docker run --help'.

I don't think you made it an official dockerhub build. I did find https://hub.docker.com/r/lirantal/dockly/ so perhaps you meant:

docker run -it --name dockly -v /var/run/docker.sock:/var/run/docker.sock lirantal/dockly:latest

But still that dockerhub is empty.

Move on-the-fly variables to constants

containerStatus.widget.js snippet:

        stack.push({
          percent: Math.round((data.ContainersRunning / data.Containers) * 100),
          stroke: 'green'
        })
  • replace the string colors with class level constants
  • do the same for other parts of the code where it makes sense

Error: Unable to determine the domain name

Hi,

I have this problem (with a nice error message by the way, so kudos for that).

How can I solve this?

Thanks in advance

Error: Unable to determine the domain name
    at new ClientRequest (_http_client.js:25:13)
    at Object.exports.request (http.js:31:10)
    at Object.request (/usr/local/lib/node_modules/dockly/node_modules/docker-modem/lib/http.js:51:52)
    at Object.get (/usr/local/lib/node_modules/dockly/node_modules/docker-modem/lib/http.js:80:19)
    at ClientRequest.<anonymous> (/usr/local/lib/node_modules/dockly/node_modules/docker-modem/lib/http.js:69:40)
    at ClientRequest.g (events.js:291:16)
    at emitOne (events.js:101:20)
    at ClientRequest.emit (events.js:188:7)
    at HTTPParser.parserOnIncomingClient [as onIncoming] (_http_client.js:474:21)
    at HTTPParser.parserOnHeadersComplete (_http_common.js:99:23)

Make the "shell" action to start the `dockerRunScript.sh` script using a terminal application

Expected Behavior

pressing 'L' should open a login shell to the selected container

Actual Behavior

The file dockerRunScript.sh is opened in a text editir (XCode)

Steps to Re-produce the Problem

  1. start dockly

  2. press 'l'

  3. dockerRunScript.sh opens in XCode

Context

  • Operating System: macOS 10.13.3
  • Node.js version (run node --version): 8.10.0
  • Package version:
  • Docker version (run docker --version): 18.03.0-ce, build 0520e24
  • Is docker installed locally? yes
  • Do you have containers created? yes
  • Does this file exists /var/run/docker.sock ? yes
  • Output of docker info:

Containers: 3
Running: 2
Paused: 0
Stopped: 1
Images: 44
Server Version: 18.03.0-ce
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge host ipvlan macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: cfd04396dc68220d1cecbe686a6cc3aa5ce3667c
runc version: 4fc53a81fb7c994640722ac585fa9ca548971871
init version: 949e6fa
Security Options:
seccomp
Profile: default
Kernel Version: 4.9.87-linuxkit-aufs
Operating System: Docker for Mac
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 1.952GiB
Name: linuxkit-025000000001
ID: YWTZ:UZVV:RABG:5NRK:C2AC:Q2CR:QT5N:GXYT:7FCX:PWED:CHTF:MWMK
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): true
File Descriptors: 35
Goroutines: 53
System Time: 2018-04-17T21:55:18.3367154Z
EventsListeners: 2
HTTP Proxy: docker.for.mac.http.internal:3128
HTTPS Proxy: docker.for.mac.http.internal:3129
Registry: https://index.docker.io/v1/
Labels:
Experimental: true
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false

Integrate with Dive

This is really cool. Thanks for your work! I also know of this other great CLI tool called dive which lets you inspect the file system of a docker image at each layer.

It would be really cool if you could integrate this feature via a keybinding/command. I think this would bring a lot of utility to a high level tool like this.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.