Giter VIP home page Giter VIP logo

tailscale-systray's Introduction

tailscale-systray

Linux port of tailscale system tray menu.

tailscale-systray

Usage

$ tailscale-systray

Requirements

  • tailscale

Installation

Install requirements

Building app requires gcc, libgtk-3-dev, libayatana-appindicator3-dev

sudo apt-get install gcc libgtk-3-dev libayatana-appindicator3-dev

Install app

go install -v github.com/mattn/tailscale-systray@latest

At this point you can start it with tailscale-systray.

Run at startup

You can do this in different ways. One option is to add the command to "Startup Applications" if your system has it:

tailscale-systray startup

License

MIT

Icon file is copied from official repository.

Author

Yasuhiro Matsumoto

tailscale-systray's People

Contributors

codenoid avatar davidosomething avatar j-fuentes avatar jfaldanam avatar mattn avatar michaelbeaumont avatar rahulsriram avatar somuchforsubtlety 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

tailscale-systray's Issues

Feature request: sort the new Mullvad exit nodes per country

The newly added Mullvad exit nodes allow a regular VPN with Tailscale.
Since there are a LOT of exit nodes to choose from, it currently fills the whole screen with exit nodes and doesn't display all of them due to this behavior.
image

It would be nice to have those nodes sorted per country so that it would look like
Network devices -> my devices -> own nodes -> device xy
Network devices -> my devices -> Mullvad nodes -> DE -> device de-xy*

This would allow operating the Mullvad nodes via tailscale-systray.

Add version information

Thanks again for this project.

I would like to package this for NixOS. Could you please add version information and/or tagged releases?

Relevant: #10.

Services

I never see any "services" in the systray, though some are available from my machine. How do we know a peer being displayed in status with surrounding () means it's a service? It seems to be enough not to have a proper DNS name for a peer (though I'm not sure what would cause that either).

Build releases, maybe even packages?

First off, thank you for writing this!

I'd love to see either releases or maybe even distro packages. Seems like the former is a lighter lift since it can all be done with GitHub actions.

bug: systray are suddenly closed when "My Devices" content height > screen height

I have more than 30 tailscale machines, the first time I open the "My Devices" menu, the systray suddenly closed (entirely, but program not exited)

the weird thing is, the systray are still shown if I show the taskbar panel anywhere but bottom

I come with conclusion that this may dash-to-panel error, or it is systray error

How i debug:

Screenshot from 2021-10-14 00-24-31

may the solution are(?):

  1. Scrollable list
  2. Horizontally expanded menu

Edit:

  1. It may because of redraw that triggered by the main endless loop (sleep 10s)

Keep the systray after closing the terminal

Maybe it's a noob question, but how can I keep the tray running after closing the terminal where I run ./tailscale-systray?

I tried with ./tailscale-systray -d as I would have done with a docker container but it didn't work, is there a specific command for go programs to "demonize" them?

Panic when logged out

When running tailscale-systray when the daemon is not running it appears as normal. Clicking "Connect" in the menu prompts me to start the daemon, so I ran systemctl start tailscaled. Once the daemon starts the systray program crashes.

Running it in the terminal:

$ tailscale-systray 
panic: runtime error: index out of range [0] with length 0

goroutine 23 [running]:
main.onReady.func4()
github.com/mattn/tailscale-systray/main.go:155 +0x885
created by main.onReady
github.com/mattn/tailscale-systray/main.go:121 +0x43d

Running tailscale status in the terminal:

Text output
Logged out
JSON output
{
"Version": "1.20.4",
"BackendState": "NeedsLogin",
"AuthURL": "",
"TailscaleIPs": null,
"Self": {
"ID": "",
"PublicKey": "nodekey:0000000000000000000000000000000000000000000000000000000000000000",
"HostName": "local-machine",
"DNSName": "",
"OS": "linux",
"UserID": 0,
"TailscaleIPs": null,
"Addrs": [],
"CurAddr": "",
"Relay": "",
"RxBytes": 0,
"TxBytes": 0,
"Created": "0001-01-01T00:00:00Z",
"LastWrite": "0001-01-01T00:00:00Z",
"LastSeen": "0001-01-01T00:00:00Z",
"LastHandshake": "0001-01-01T00:00:00Z",
"Online": false,
"KeepAlive": false,
"ExitNode": false,
"ExitNodeOption": false,
"Active": false,
"PeerAPIURL": null,
"InNetworkMap": false,
"InMagicSock": false,
"InEngine": false
},
"Health": [
"state=NeedsLogin, wantRunning=false"
],
"MagicDNSSuffix": "",
"CertDomains": null,
"Peer": null,
"User": null
}

Seems like it doesn't handle when .TailscaleIPs is null.

Versions

  • Tailscale 1.20.4
  • tailscale-systray on git 6434789
  • KDE Plasma 5.24.1
  • Arch Linux (with kernel 5.16.10-zen)

Add License File ?

Thanks for the project. Can you please add a license to the repo?

Edit: I just noticed MIT is mentioned in the Readme. I am going to close this for now.

ignore client version warning

if using tailscale client built from source (or tailscale-git from archlinux repo), you may get a message:

% tailscale ip -4
Warning: client version "1.17.12-tb382161fe" != tailscaled server version "1.17.8-t5d6198ade"
100.xxx.xxx.xxx

The server warning message should be ignored so the IP can be properly output in

for {
b, err := exec.Command("tailscale", "ip", "-4").CombinedOutput()
if err != nil {
if enabled {
systray.SetTooltip("Tailscale: Disconnected")
mConnect.Enable()
mDisconnect.Disable()
systray.SetIcon(iconOff)
enabled = false
}
time.Sleep(10 * time.Second)
continue
}
myIP := strings.TrimSpace(string(b))

Change icon on systray

Hi there,

Thank you for writing this app, it's very useful. I only have one question: anyway to change the icon?

Cheers!

Compilation issue

Trying to build the code with go build I get:

# runtime/internal/sys
/usr/lib/go/src/runtime/internal/sys/consts.go:13:7: StackGuardMultiplier redeclared in this block
	/usr/lib/go/src/runtime/internal/sys/arch.go:27:7: other declaration of StackGuardMultiplier
/usr/lib/go/src/runtime/internal/sys/consts.go:16:7: DefaultPhysPageSize redeclared in this block
	/usr/lib/go/src/runtime/internal/sys/arch.go:36:7: other declaration of DefaultPhysPageSize
/usr/lib/go/src/runtime/internal/sys/consts.go:20:7: PCQuantum redeclared in this block
	/usr/lib/go/src/runtime/internal/sys/arch.go:40:7: other declaration of PCQuantum
/usr/lib/go/src/runtime/internal/sys/consts.go:23:7: Int64Align redeclared in this block
	/usr/lib/go/src/runtime/internal/sys/arch.go:43:7: other declaration of Int64Align
/usr/lib/go/src/runtime/internal/sys/consts.go:30:7: MinFrameSize redeclared in this block
	/usr/lib/go/src/runtime/internal/sys/arch.go:50:7: other declaration of MinFrameSize
/usr/lib/go/src/runtime/internal/sys/consts.go:34:7: StackAlign redeclared in this block
	/usr/lib/go/src/runtime/internal/sys/arch.go:54:7: other declaration of StackAlign

Using Go 1.19.2 in Linux

How to compile

Instructions because I have never compiled go before.

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.