TUI Client for Docker

docui - TUI Client for Docker Written in Go

Go Report Card CircleCI CircleCI GitHub All Releases GitHub commits

About docui

demo

docui is a TUI Client for Docker. It can do the following:

  • image

    • search/pull/remove
    • save/import/load
    • inspect/filtering
  • container

    • create/remove
    • start/stop/kill
    • export/commit
    • inspect/rename/filtering
    • exec cmd
  • volume

    • create/remove
    • inspect/filtering
  • network

    • remove
    • inspect/filtering

Supported OSes

  • Mac
  • Linux

Required Tools

  • Go Ver.1.11.4~
  • Docker Engine Ver.18.06.1~
  • Git

Installation

Environment variables

The following environment variables must be set.

export LC_CTYPE=en_US.UTF-8
export TERM=xterm-256color

From Source

If you have not installed go and set GOPATH/GOBIN, you must install and set env before installing docui.

This project uses Go Modules for dependencies introduced in Go 1.11.

Use go get or git clone:

$ go get -d github.com/skanehira/docui
$ cd $GOPATH/src/github.com/skanehira/docui
$ GO111MODULE=on go install
$ git clone https://github.com/skanehira/docui.git
$ cd docui/
$ GO111MODULE=on go install

Make sure your PATH includes the $GOPATH/bin directory so your commands can be easily used:

export PATH=$PATH:$GOPATH/bin

Homebrew

$ brew install docui

Nix

docui is available on nixpkgs unstable channel:

$ nix-env -i docui

Update

Use git pull:

$ git pull
$ GO111MODULE=on go install

Log file

Check wiki.

Use on Docker

$ docker run --rm -itv /var/run/docker.sock:/var/run/docker.sock skanehira/docui

Build Docker Image

$ make docker-build

Keybindings

panel operation key
all change panel Tab / Shift + Tab
all quit q
list panels next entry j /
list panels previous entry k /
list panels next page Ctrl / f
list panels previous page Ctrl / b
list panels scroll to top g
list panels scroll to bottom G
image list pull image p
image list search images f
image list remove image d
image list create container c
image list inspect image Enter
image list save image s
image list import image i
image list load image Ctrl + l
image list refresh image list Ctrl + r
image list filter image /
container list inspect container Enter
container list remove container d
container list start container u
container list stop container s
container list kill container Ctrl + k
container list export container e
container list commit container c
container list rename container r
container list refresh container list Ctrl + r
container list filter image /
container list exec container cmd Ctrl + e
container logs show container logs Ctrl + l
volume list create volume c
volume list remove volume d
volume list inspect volume Enter
volume list refresh volume list Ctrl + r
volume list filter volume /
network list inspect network Enter
network list remove network d
network list filter network /
pull image pull image Enter
pull image close panel Esc
create container next input box Tab
create container previous input box Shift + Tab
detail cursor dwon j
detail cursor up k
detail next page Ctrl / f
detail previous page Ctrl / b
search images search image Enter
search images close panel Esc
search result next image j
search result previous image k
search result pull image Enter
search result close panel q
create volume close panel Esc
create volume next input box Tab
create volume previous input box Shift + Tab

How to use

For details of the input panel please refer to wiki

Alternatives

  • lazydocker A simple terminal UI for both docker and docker-compose, written in Go with the gocui library.
  • docker.vim Manage docker containers and images in Vim
  • See Awesome Docker list for similar tools to work with Docker.
Owner
skanehira
Like Vim, Go. Many CLI/TUI Tools, Vim plugin author.
skanehira
Comments
  • Cannnot attach container from remote access.

    Cannnot attach container from remote access.

    When I press a in container list panel,there is no system reaction and can't attach container. But I run docker attach commnad from prompt, it runs normaly.

    Environment Local OS : Windows 10 Remote OS : Amazon Linux AMI 2018.03 Docker Version : 18.06.1-ce Remote access tool : Teraterm 4.11 and RLogin 2.4

  • install error

    install error

    @d-kuro I run go install and got errors. Do you understand the cause?

    go: downloading github.com/docker/docker v0.7.3-0.20180827131323-0c5f8d2b9b23
    go: verifying github.com/docker/[email protected]: checksum mismatch
            downloaded: h1:mJtkfC9RUrUWHMk0cFDNhVoc9U3k2FRAzEZ+5pqSIHo=
            go.sum:     h1:Zl/9mUfPbYbnv895OXx9WfxPjwqSZHohuZzVcjJ5QPQ=
    ```
  • Doesn't correctly work in Ubuntu18.04

    Doesn't correctly work in Ubuntu18.04

    Hi I'm really impressed your project and I want to use it. But it doesn't correctly work in Ubuntu18.04.

    Summary

    • Doesn't launch in tmux
    • Startup in normal shell, but UI is collapsed
    • Using docker, everything work

    Doesn't launch in tmux

    If i'm using tmux, docui doesn't launch with no error. I checked $HOME/docui.log, there is no log. This is preview. docui_tmux

    Startup in normal shell, but UI is collapsed

    If i use normal shell (not tmux), docui command launch application. However, UI is something wrong. Please look at this gif docui_normal

    I'm so sorry the character is too small. Some vertical black lines are displayed and they hide important characters like 'I' of 'ID' in header.

    Using docker, everything work

    If i use dockerized docui, everything work fine. UI is correct, and if i used tmux, it's fine. docui_docker

    My Environment

    • OS: Ubuntu 18.04.3 LTS
    • docker: Docker version 19.03.1, build 74b1e89
    • docui: bd2021d6e1b6da00ca7b842679648d577bac0c53
  • error on go get on raspi

    error on go get on raspi

    Installation mostly worked. But when compiling the go 11 parts, there is an error. Should this work or is it an unsupported platform?

    # github.com/skanehira/docui/docker
    docker/container.go:86: cannot use "github.com/docker/go-connections/nat".PortMap literal (type "github.com/docker/go-connections/nat".PortMap) as type "github.com/docker/docker/vendor/github.com/docker/go-connections/nat".PortMap in assignment
    
  • Add installation method for Linux distributions other than CentOS.

    Add installation method for Linux distributions other than CentOS.

    Does docui support all Linux distributions that can use docker?

    On wiki, the installation method for Linux supported only CentOS. So I added for Linux distributions that can use docker, other than CentOS.

    If it have support, please consider this pull-request : )

  • Add goreleaser to support Homebrew installation

    Add goreleaser to support Homebrew installation

    fix #91

    Summary

    This PR is to support Homebrew tap.

    I researched about using Homebrew again, I knew below:

    • It is necessary to set release version to use Homebrew.
    • Using Homebrew tap is easier to follow the latest version than using offitial Homebrew repo.

    Sorry for not able to using Homebrew with the latest commit of master branch.. 😢

    How to use it

    In order to be ready to use this, let me request to @skanehira to do below.

    1. Create the empty GitHub repo named skanehira/homebrew-docui and add empty Formula folder. (My test example: https://github.com/gotchane/homebrew-docui)
    2. Set the Environment variable GITHUB_TOKEN to docui circleci project to use goreleaser.

    That's all. When only pushing git tag like 1.0.x at releasing, goreleaser is kicked from circleci, build and set binary releases to GitHub releases and update homebrew tap file.

    Any comments and questions are welcome 😃

  • Ability to install or pull default docker images

    Ability to install or pull default docker images

    As some users have load of images that they use as default. It would be nice to be able to pull certain images automatically if they are not already installed on system.

    When using docker at first run it feels cumbersome to load one by one and sometimes some might forget what images to use.

  • [Bug] Enable to run docui on small terminal window

    [Bug] Enable to run docui on small terminal window

    Thanks for creating docui. This project is awesome! I would like to ask a question.

    When I use docui on tmux + iTerm2 on Mac OSX, but the error below happened.

    panic: invalid dimensions
    
    goroutine 1 [running]:
    github.com/skanehira/docui/panel.(*Gui).init(0xc4205fe240)
            /Users/gotchane/go/src/github.com/skanehira/docui/panel/gui.go:198 +0xece
    github.com/skanehira/docui/panel.New(0x2, 0xc4205b3f78)
            /Users/gotchane/go/src/github.com/skanehira/docui/panel/gui.go:94 +0x150
    main.main()
            /Users/gotchane/go/src/github.com/skanehira/docui/main.go:13 +0x2eanic: invalid dimensions
    

    However, according to issue #66, it works fine when I increase window size.

    If possible, I would like to fix this issue, could I? (However I'm newbie of golang...)

    If there are already some outlines of fixing this issue, I'll follow them.

    Any comments are welcome.

  • Add basicly CircleCI config

    Add basicly CircleCI config

    Hey guys, Thank you for making a so nice & cool tool.

    BTW, I thought that CI was necessary for this repo, I wrote the CircleCI (for 2.1 version) configuration file. Note: If you don't use CircleCI with this repo's policy, please close this PR.

    🦍Need discuss🦍

    Which Lint tool do we need to use?

    • Currently is most simply, golint ./... only.
    • Should we use gometalinter?
    • Or, not lint check at CircleCI?

    I don't have deep experience on CircleCI & Golang. If you have a good way, please tell me.

    Thank's for reading.

  • nil deref panic on ctrl-L with no containers running

    nil deref panic on ctrl-L with no containers running

    My local docker currently has no containers running; exploring docui on a fresh download ( 08d7aa1ad7 ) I pressed Ctrl-L and got a nil dereference panic.

    panic: runtime error: invalid memory address or nil pointer dereference
    [signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x82e10f]
    
    goroutine 84 [running]:
    github.com/skanehira/docui/panel.(*ContainerList).ShowContainerLogs.func1(0xc000356380, 0xc0003904e0)
    	/home/pdp/go/src/github.com/skanehira/docui/panel/containerPanel.go:716 +0x8f
    created by github.com/skanehira/docui/panel.(*ContainerList).ShowContainerLogs
    	/home/pdp/go/src/github.com/skanehira/docui/panel/containerPanel.go:708 +0x1e7
    

    Compiled with go1.13beta1. But really, "no containers, ask to view logs of container, get a panic".

  • can't run docui on macOS

    can't run docui on macOS

    Thank you for creating useful tools. A problem occurred when installing.

    I did:

    $ go get -d github.com/skanehira/docui
    $ cd $GOPATH/src/github.com/skanehira/docui
    $ GO111MODULE=on go install
    $ docui
    panic: invalid dimensions
    
    goroutine 1 [running]:
    github.com/skanehira/docui/panel.(*Gui).init(0xc000072300)
    	/Users/mimikun/go/src/github.com/skanehira/docui/panel/gui.go:192 +0xf57
    github.com/skanehira/docui/panel.New(0x2, 0x1446a20)
    	/Users/mimikun/go/src/github.com/skanehira/docui/panel/gui.go:94 +0x138
    main.main()
    	/Users/mimikun/go/src/github.com/skanehira/docui/main.go:13 +0x2e
    

    my envrionments:

    • macOS 10.14.2
    • Docker CE v18.09.1
    • Go v1.11.4 darwin/amd64

    Thanks.

  • Dockerfile for use with raspberry 64bit

    Dockerfile for use with raspberry 64bit

    Tried to get docui running on raspberry pi 64bit To build it directly via docker you may use following:

    # build docui
    FROM golang:1.16.0 AS build-docui
    ENV GOOS linux
    ENV GOARCH=arm
    ENV GOARM=7
    ENV CGO_ENABLED 0
    COPY . ./src/github.com/skanehira/docui
    WORKDIR /go/src/github.com/skanehira/docui
    RUN go build
    
    # copy artifact from the build stage
    FROM busybox:1.33
    ENV TERM "xterm-256color"
    COPY --from=build-docui /go/src/github.com/skanehira/docui/docui /usr/local/bin/docui
    
    ENTRYPOINT ["docui"]```
    
    Maybe someone could do a multiarch Dockerfile 
  • [Feature Request] Ubuntu support

    [Feature Request] Ubuntu support

    Would be nice to have this easily available for ubuntu. E.g. as a PPA, or in the long-term in the repositories.

    I know not everyone uses ubuntu, but it is the most popular desktop distro, so making this app easily available for ubuntu would be awesome.

  • Open in browser

    Open in browser

    Most containers expose some http port. We can open it in browser. For simplicity we can just open first container's published port. We'll determine the ip:port on container creation and store to meta "Web Port". To open browser on any platform was added a new dependency github.com/pkg/browser which is very small.

    The similar functionality already exists in DockerStation

  • runtime errors

    runtime errors

    docui crashes very often when trying to press 'd' to delete volumes or containers My suspicion is, it's mostly when the volume has been already deleted but is not yet gone from the UI (pressing d twice). Also a crash when pressing 'd' in an empty list of containers.

    $ docui
    panic: runtime error: invalid memory address or nil pointer dereference [recovered]
    	panic: runtime error: invalid memory address or nil pointer dereference
    [signal SIGSEGV: segmentation violation code=0x1 addr=0x18 pc=0x147c933]
    
    goroutine 1 [running]:
    github.com/rivo/tview.(*Application).Run.func1(0xc000360280)
    	/go/pkg/mod/github.com/rivo/[email protected]/application.go:149 +0x82
    panic(0x1512480, 0x19f8e10)
    	/usr/local/go/src/runtime/panic.go:522 +0x1b5
    github.com/skanehira/docui/gui.(*Gui).removeContainer.func1()
    	/go/src/github.com/skanehira/docui/gui/keybindings.go:337 +0x33
    github.com/skanehira/docui/gui.(*Gui).confirm.func1(0x0, 0x159f80f, 0x4)
    	/go/src/github.com/skanehira/docui/gui/gui.go:295 +0xbf
    github.com/rivo/tview.(*Modal).AddButtons.func1.1()
    	/go/pkg/mod/github.com/rivo/[email protected]/modal.go:86 +0x53
    github.com/rivo/tview.(*Button).InputHandler.func1(0xc00000cae0, 0xc0003f4050)
    	/go/pkg/mod/github.com/rivo/[email protected]/button.go:129 +0x69
    github.com/rivo/tview.(*Box).WrapInputHandler.func1(0xc00000cae0, 0xc0003f4050)
    	/go/pkg/mod/github.com/rivo/[email protected]/box.go:152 +0x5d
    github.com/rivo/tview.(*Application).Run(0xc000360280, 0x0, 0x0)
    	/go/pkg/mod/github.com/rivo/[email protected]/application.go:234 +0x396
    github.com/skanehira/docui/gui.(*Gui).Start(0xc0003660a0, 0xc0003660a0, 0xc00036a240)
    	/go/src/github.com/skanehira/docui/gui/gui.go:211 +0x4e
    main.run(0xc000098120)
    	/go/src/github.com/skanehira/docui/main.go:35 +0x33b
    main.main()
    	/go/src/github.com/skanehira/docui/main.go:45 +0x74
    

    and

    $ docui
    panic: runtime error: index out of range [recovered]
    	panic: runtime error: index out of range
    
    goroutine 1 [running]:
    github.com/rivo/tview.(*Application).Run.func1(0xc000358300)
    	/go/pkg/mod/github.com/rivo/[email protected]/application.go:149 +0x82
    panic(0x1512480, 0x19f8e50)
    	/usr/local/go/src/runtime/panic.go:522 +0x1b5
    github.com/skanehira/docui/gui.(*Gui).selectedVolume(0xc000237ac0, 0x0)
    	/go/src/github.com/skanehira/docui/gui/gui.go:259 +0x9f
    github.com/skanehira/docui/gui.(*Gui).removeVolume(0xc000237ac0)
    	/go/src/github.com/skanehira/docui/gui/keybindings.go:349 +0x2f
    github.com/skanehira/docui/gui.(*volumes).setKeybinding.func1(0xc000236020, 0xc0003dc001)
    	/go/src/github.com/skanehira/docui/gui/volumes.go:55 +0x87
    github.com/rivo/tview.(*Box).WrapInputHandler.func1(0xc000236020, 0xc0003dc010)
    	/go/pkg/mod/github.com/rivo/[email protected]/box.go:149 +0x75
    github.com/rivo/tview.(*Application).Run(0xc000358300, 0x0, 0x0)
    	/go/pkg/mod/github.com/rivo/[email protected]/application.go:234 +0x396
    github.com/skanehira/docui/gui.(*Gui).Start(0xc000237ac0, 0xc000237ac0, 0xc000243200)
    	/go/src/github.com/skanehira/docui/gui/gui.go:211 +0x4e
    main.run(0xc00009e0c0)
    	/go/src/github.com/skanehira/docui/main.go:35 +0x33b
    main.main()
    	/go/src/github.com/skanehira/docui/main.go:45 +0x74
    
  • docui changes the terminal background color to black

    docui changes the terminal background color to black

    Docui changes my terminals background color to black, this looks very awful when run in tmux.

    Is there a way to change that? it like to not touch the background color.

Chief Client Go is a cross platform Krunker client written in Go Lang

Chief Client Go Chief Client Go is a client for Mac and Linux written in GoLang Features Ad Blocker Option to use proxy Installation To install this c

Nov 6, 2021
Docker CE

Docker CE ⚠️ This repository is now deprecated and will be archived ⚠️ Starting with the Docker 20.10 release, packages for the Docker Engine and Dock

Jan 6, 2023
Gorsair hacks its way into remote docker containers that expose their APIs
Gorsair hacks its way into remote docker containers that expose their APIs

Gorsair Gorsair is a penetration testing tool for discovering and remotely accessing Docker APIs from vulnerable Docker containers. Once it has access

Dec 31, 2022
Experimental code execution microservice based on Docker containers.
Experimental code execution microservice based on Docker containers.

ranna ランナー - Experimental code runner microservice based on Docker containers. ⚠ PLEASE READ BEFORE USE First of all, this project is currently work i

Dec 9, 2022
Generate random, pronounceable, sometimes even memorable, "superhero like" codenames - just like Docker does with container names.

Codename an RFC1178 implementation to generate pronounceable, sometimes even memorable, "superheroe like" codenames, consisting of a random combinatio

Dec 11, 2022
Workaround for running ubuntu:21.10, fedora:35, and other glibc >= 2.34 distros on Docker <= 20.10.9

clone3-workaround: Workaround for running ubuntu:21.10, fedora:35, and other glibc >= 2.34 distros on Docker <= 20.10.9 Old container engines such as

Dec 1, 2022
Monitoring Go application inside docker container by InfluxDB, Telegraf, Grafana
Monitoring Go application inside docker container by InfluxDB, Telegraf, Grafana

REST API for TreatField app Docker compose for TIG and Golang simple app: https://github.com/tochytskyi/treatfield-api/blob/main/docker-compose.yml Gr

Nov 6, 2021
A Simple Bank Web Service implemented in Go, HTTP & GRPC, PostgreSQL, Docker, Kubernetes, GitHub Actions CI

simple-bank Based on this Backend Master Class by TECH SCHOOL: https://youtube.com/playlist?list=PLy_6D98if3ULEtXtNSY_2qN21VCKgoQAE Requirements Insta

Dec 9, 2021
Bank-End Master Class [ Golang, Postges, Docker ]

Simple Bank This repository contains the codes of the Backend master class course by TECH SCHOOL. In this backend master class, we’re going to learn e

Dec 14, 2021
With Docker and Go, Mysql, Redis, Selenium.

golang-app Go, Mysql, Redis, Selenium. To run locally Have docker & docker-compose installed on your operating system. cp .env.example .env && docker-

Aug 31, 2022
Temporal Server docker-compose files

Temporal Server docker-compose files This repository provides docker-compose fil

Dec 24, 2021
Curso Docker desde cero

Curso Docker desde cero Según la última encuesta realizada por Stack OverFlow, publicada en febrero de 2020, Docker se posiciona en la casilla número

Aug 29, 2022
a Go (Golang) MusicBrainz WS2 client library - work in progress
a Go (Golang) MusicBrainz WS2 client library - work in progress

gomusicbrainz a Go (Golang) MusicBrainz WS2 client library - a work in progress. Current state Currently GoMusicBrainz provides methods to perform sea

Sep 28, 2022
Selenium WebDriver client for Go

============================================== go-selenium - Selenium WebDriver client for Go go-selenium is a Selenium WebDriver client for Go. Note:

Dec 10, 2022
Yubigo is a Yubikey client API library that provides an easy way to integrate the Yubico Yubikey into your existing Go-based user authentication infrastructure.

yubigo Yubigo is a Yubikey client API library that provides an easy way to integrate the Yubikey into any Go application. Installation Installation is

Oct 27, 2022
Simple Client Implementation of WebFinger

Go-Webfinger Go client for the Webfinger protocol Go-Webfinger is a Go client for the Webfinger protocol. *It is a work in progress, the API is not fr

Nov 18, 2022
An example client implementation written in GO to access the CyberVox platform API

About This is an example client implementation written in GO to access the CyberVox platform API.

Nov 7, 2022
Elastic is an Elasticsearch client for the Go programming language.

Elastic is an Elasticsearch client for the Go programming language.

Jan 9, 2023
Geth client which picks the most profitable blocks to mine using a greedy algorithm

Greeden-Geth Greeden-Geth is a protocol-agnostic client which uses a greedy algorithm to pick the most profitable blocks to submit to the network out

Nov 16, 2022