Skip to content

An efficiency terminal tool, which support ssh server search & select.

License

Notifications You must be signed in to change notification settings

sisyphsu/smart-server-selector

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

42 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

smart-server-selector

smart-server-selector is an efficiency terminal tool for backend system development engineer, especially for someone who have bunch of servers to switch.

It was developed with golang, which means it's very clean, no dependency and cross-platform.

In terms of features, it support keyword search, which could help you find server by hostname, ip, description, etc quickly.

Hope it could save your time.

Demo

demo

Install

You can find the download links at this page.

smart-server-selector support these platforms (May not be updated timely):

Installation is very easy.

You can use wget or curl download it, example for linux-amd64:

wget https://github.com/sisyphsu/smart-server-selector/releases/download/{version}/smart-server-selector-linux-amd64
curl https://github.com/sisyphsu/smart-server-selector/releases/download/{version}/smart-server-selector-linux-amd64 > smart-server-selector-linux-amd64 
chmod +x smart-server-selector-linux-amd64
mv smart-server-selector-linux-amd64 ~/.local/bin/sss 

Above steps download the smart-server-selector into ~/.local/bin, and name it sss, which is more convenient for keyboard inputting.

You should add ~/.local/bin directory into your $PATH, or using other PATH directory, this isn't a prerequisite, but you better do it.

The whole process didn't need any additional permission like root.

Configuration

After started, smart-server-selector will load servers from ~/.servers, you can edit this file directly.

These two format configurations are valid:

# comments, empty line is ok.
test    10.10.10.1   description
test    10.10.10.1   22     username   description

Explain:

  • test: environment name, like test/pre/prod, no limit.
  • 10.10.10.1: host name, could ip or hostname.
  • 22: ssh port
  • username: ssh login name
  • description: any text

If your configuration is invalid, smart-server-selector will ignore it and print notice info.

Advice

If your server's ssh port or ssh username don't match the default value, then you should config it in global ssh config(~/.ssh/config), for example:

Host *
        Port 9876
        User other-name
        TCPKeepAlive yes
        ServerAliveInterval 60
        StrictHostKeyChecking no

This way could keep the server-list clean, and no need to config port or user for each server.

For more details, check this link.

Thanks

UI powered by tview and tcell.

License

MIT

About

An efficiency terminal tool, which support ssh server search & select.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages