Skip to content

A CLI to easily list, search and connect to SSH hosts via GoTeleport service. This CLI is just a wrapper around tsh command provided by Goteleport application.

License

Notifications You must be signed in to change notification settings

beliven-it/tssh

Repository files navigation



A CLI to easily list, search and connect to SSH hosts via GoTeleport service. This CLI is just a wrapper around tsh command provided by Goteleport application.

Install

Add Homebrew Beliven tap with:

  brew tap beliven-it/tap

Then install tssh CLI with:

  brew install beliven-it/tap/tssh

Configuration

Run tssh init to generate config file inside ~/.config/tssh/config.yml (works only if not exists yet) or let the CLI creating it automatically on first run (every command).

fzf options

See the man page (man fzf) for the full list of available options and add the desired ones to the fzf_options string inside ~/.config/tssh/config.yml. See more about the fzf options in the official repository.

Config file example

This is a complete config file example with two providers:

# TSSH configuration file
fzf_options: "-i"

# Admin users can be identifier by a role.
# For security reasons this role is default set to empty.
# If you are a admin user, set these values below.
# 
# When a user have the role declared the system force the 
# user to connect with a specific privileged user defined by 
# the admin_user variable.
#
# example:
#
# admin_role: "sysadmin"
# admin_user: "root"
#
# launching tssh c the results are a list of the host the user can connect
# and instead to use the role convension host.user, the user will be replaced
# by root value.
admin_role: "<YOUR PRIVILEGED ROLE IDENTIFIER>"

# TSSH Easily allow to login or logout into the cluster.
# compile the following values for handle login actions.
teleport_proxy: "teleport.domain.com" 
teleport_user: "my_user"

# If you need to use the passwordless feature by default you can enable with this setting
teleport_passwordless: true

Usage

To see available commands and options, run: tssh, tssh help, tssh --help or tssh -h.

Development

Clone the repository and run inside the folder:

  • go mod init tssh
  • go mod vendor
  • go build -ldflags="-X tssh/cmd.Version=1.0.0"

Run ./tssh inside the folder to test the CLI.

Use as normal SFTP, SSH and other services

You can also use as normal behavior.

Have found a bug?

Please open a new issue here.

License

Licensed under MIT

About

A CLI to easily list, search and connect to SSH hosts via GoTeleport service. This CLI is just a wrapper around tsh command provided by Goteleport application.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages