Skip to content

Terminal - A powerful terminal server / client,support Web Terminal

Notifications You must be signed in to change notification settings

go-zoox/terminal

Repository files navigation

Terminal - A powerful terminal server / client,support Web Terminal

PkgGoDev Build Status Go Report Card Coverage Status GitHub issues Release

Installation

To install the package, run:

# with go
go install github.com/go-zoox/terminal/cmd/terminal@latest

if you dont have go installed, you can use the install script (zmicro package manager):

curl -o- https://raw.githubusercontent.com/zcorky/zmicro/master/install | bash

zmicro package install terminal

Features

  • Server
    • Authentication
      • Basic Auth (username/password)
      • Bearer Token
      • OAuth2
      • Custom Auth Server
    • Driver Runtime
      • Host
      • Docker
        • Custom Docker Image
      • Kubernetes
      • SSH
    • Read Only
    • Init Command
  • Client
    • Web Terminal/Client (Browser)
      • Auth
        • Basic Auth
    • Command Line Client (CLI)
      • Auth
        • Basic Auth
      • Custom Shell
      • Custom Workdir
      • Custom User
      • Custom Env
      • Env File
      • Custom Docker Image
      • Run Command Once
      • Run Script File

Quick Start

Start Terminal Server

terminal server

Connect Terminal with Client

terminal client --server ws://127.0.0.1:8838/ws

Connect Terminal with browser

open http://127.0.0.1:8838

Usage

Server

terminal server --help

NAME:
   terminal server - terminal server

USAGE:
   terminal server [command options] [arguments...]

OPTIONS:
   --port value, -p value   server port (default: 8838) [$PORT]
   --shell value, -s value  specify terminal shell [$GO_ZOOX_TERMINAL_SHELL, $SHELL]
   --init-command value     the initial command [$GO_ZOOX_TERMINAL_INIT_COMMAND]
   --username value         Username for Basic Auth [$GO_ZOOX_TERMINAL_USERNAME]
   --password value         Password for Basic Auth [$GO_ZOOX_TERMINAL_PASSWORD]
   --driver value           Driver runtime, options: host, docker, kubernetes, ssh, default: host (default: "host") [$GO_ZOOX_TERMINAL_DRIVER]
   --driver-image value     Driver image for driver runtime, default: whatwewant/zmicro:v1 (default: "whatwewant/zmicro:v1") [$GO_ZOOX_TERMINAL_DRIVER_IMAGE]
   --disable-history        Disable history (default: false) [$GO_ZOOX_TERMINAL_DISABLE_HISTORY]
   --read-only              Read Only (default: false) [$GO_ZOOX_TERMINAL_READ_ONLY]
   --help, -h               show help

Client

terminal client --help

NAME:
   terminal client - terminal client

USAGE:
   terminal client [command options] [arguments...]

OPTIONS:
   --server value, -s value                         server url [$SERVER]
   --username value                                 Username for Basic Auth [$USERNAME]
   --password value                                 Password for Basic Auth [$PASSWORD]
   --command value, -c value                        specify exec command [$COMMAND]
   --shell value                                    specify terminal shell
   --workdir value, -w value                        specify terminal workdir [$WORKDIR]
   --user value, -u value                           specify terminal user
   --env value, -e value [ --env value, -e value ]  specify terminal env [$ENV]
   --image value                                    specify image for container runtime [$IMAGE]
   --scriptfile value                               specify script file [$SCRIPTFILE]
   --envfile value                                  specify env file, format: key=value [$ENVFILE]
   --help, -h                                       show help

License

GoZoox is released under the MIT License.

About

Terminal - A powerful terminal server / client,support Web Terminal

Resources

Stars

Watchers

Forks

Packages

No packages published