aws / aws/amazon-ssm-agent

SSM and xterm issues with zsh

Open
#344 5 comments 2 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
1.2k
Forks
357
PR merge metrics
No merged PRs in 30d

Description

I have spent quite some time today trying to figure out why my tmux sessions look perfectly fine via SSH compared to when I'm connected to a server via SSM.

For example:

![image](https://user-images.githubusercontent.com/4023423/104830395-b5747880-584c-11eb-924e-e4382d846960.png)

This happens with _any_ command that has a pretty extensive output.

As you can see, the tmux panes bleed over. I figured out that it was due to the `TERM` environment variable. From the SSH session, it was set to `xterm-256color` and it worked just fine. From the prompt (after connecting via SSM), it was also the same but the tmux session was different.

When I changed this value to `ansi` it fixed my problem.

However, I'm now having the same issue in docker and I can't set the TERM to `ansi` because of some other issues. Not sure if there's anything I can "configure" per se, but just wanted to check to see if there's another way I could resolve this issue.

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the tmux pane rendering difference between SSH and SSM with TERM=xterm-256color, then compare the SSM and Docker terminal environments. Done means identifying a supported configuration or confirmed agent limitation that prevents pane bleed without changing TERM to ansi.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, docker, zsh
Domain
cli, devops
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.