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

Mirror connect to multiple hosts #20

Open
helmo opened this issue Jul 16, 2013 · 10 comments
Open

Mirror connect to multiple hosts #20

helmo opened this issue Jul 16, 2013 · 10 comments
Assignees

Comments

@helmo
Copy link
Contributor

helmo commented Jul 16, 2013

Feature request:
I love the 'c' key to quickly connect to a host.

Sometimes there are a few commands that need to be executed on a number of hosts.

It would be really great to tag these hosts, and then mirror the input to these sessions.
Could that be done via the split option in screen?

A similar thing can be done with cssh, but that's gui only.

@ghost ghost assigned liske Jul 17, 2013
@liske
Copy link
Member

liske commented Jul 17, 2013

Hi,

I don't think this could be implemented by screen's split command. It might be possible to use the stuff command to put input into multiple screen sessions in parallel... but it is not an mirroring at all.

Regards,
Thomas

@helmo
Copy link
Contributor Author

helmo commented Jul 17, 2013

@liske
Copy link
Member

liske commented Jul 21, 2013

apt-dater spawns a screen instance for each connection. Using the stuff command from outside screen (=from within apt-dater) should work to supply keyboard sequences into multiple screen instances.

@kiranos
Copy link

kiranos commented Mar 10, 2014

yea its seems in my thinking to be outside of apt-daters scope. install a package to a group of hosts I feel is what apt-dater can stop.

@helmo
Copy link
Contributor Author

helmo commented Mar 18, 2014

I understand @kiranos, it does smell like feature creep.

I'm open to suggestions though.

@kiranos
Copy link

kiranos commented Mar 18, 2014

@helmo I use terminator and broadcast in such cases:

"Not just that. You can group several splits into one group. Once you have grouped, you can broadcast a single command to all the splits in a group. “Type once and execute everywhere”. Awesome egh?"

@kallies
Copy link

kallies commented Oct 25, 2017

Ansible might be the tool for this usecase. If it's for preparation of the update process it might be relevant for apt-dater. In that case i'd love to see the specific usecase.

@helmo
Copy link
Contributor Author

helmo commented Oct 26, 2017

For repeated tasks definitely Ansible (or any other cm tool), what I had in mind here is more for one-off things. Possibly a bit more error prone, allowing you to correct any mistakes on the fly.

@gratuxri
Copy link
Contributor

I know, that this is really old issue, but nowadays apt-dater can use tmux and in tmux you have :set-window-option synchronize-panes on
to type same things on all panes

@nosilver4u
Copy link

Throwing another option out there for posterity, as I use dsh for this sort of thing. This allows me to setup groups for my servers and then execute a command for all servers or just for a particular group. Pretty handy!

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

No branches or pull requests

6 participants