Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

key handling behavior when autostarted via crontab #67

Open
alphajoza opened this issue Apr 6, 2023 · 1 comment
Open

key handling behavior when autostarted via crontab #67

alphajoza opened this issue Apr 6, 2023 · 1 comment

Comments

@alphajoza
Copy link

alphajoza commented Apr 6, 2023

What version of GoTTY are you using (gotty --version)?

v1.5.0

What operating system and browser are you using?

Ubuntu 22.04.2 LTS
Google Chrome 112.0.5615.50 (Official Build) (64-bit)

What did you do?

I want to run gotty upon server reboot so I added the following to crontab -e:

@reboot /root/gotty/gotty --config "/root/gotty/.gotty" tmux new -A -s gotty

the content of /root/gotty/.gotty is:

address = "1.1.1.1"
port = "1010"
enable_tls = true
tls_crt_file = "/root/cert.crt"
tls_key_file = "/root/private.key"
enable_basic_auth = true
credential = "admin:admin"
permit_write = true

What did you expect to see?

successful execution and normal operation of gotty

What did you see instead?

crontab successfully executes and runs gotty upon reboot and I can access terminal at 1.1.1.1:1010 as usual but interpretation and handling of some key combinations are now different from what was the expected behavior.

for example: ctrl + l writes literally ^L on the terminal rather than resetting it.
or pressing tab for completing a filename, writes literally a tab character (empty space)

  1. Is this a bug or because of how crontab handles the execution?

  2. If not a bug, what is the correct procedure to run gotty upon server reboot?

@alphajoza
Copy link
Author

Solved: used bash (bash -x) instead of tmux

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant