docker-archive / deploykit

A toolkit for creating and managing declarative, self-healing infrastructure.
Apache License 2.0
2.25k stars 264 forks source link

Playbook SSH backend supports localhost #902

Closed chungers closed 6 years ago

chungers commented 6 years ago

This PR makes it possible to run playbook with {{/* =% ssh %= */}} backends run locally as well as remotely when --hostport slice contains remote host and/or localhost. For example

infrakit use x do-y --hostport localhost,remote1:22 will execute the playbook using two go-routines, one against localhost (via sh) and one remotely (via ssh, on remote1:22).

Signed-off-by: David Chung david.chung@docker.com

GordonTheTurtle commented 6 years ago

Please sign your commits following these rules: https://github.com/moby/moby/blob/master/CONTRIBUTING.md#sign-your-work The easiest way to do this is to amend the last commit:

$ git clone -b "0421-fixes" git@github.com:chungers/infrakit.git somewhere
$ cd somewhere
$ git rebase -i HEAD~842354290848
editor opens
change each 'pick' to 'edit'
save the file and quit
$ git commit --amend -s --no-edit
$ git rebase --continue # and repeat the amend for each commit
$ git push -f

Amending updates the existing PR. You DO NOT need to open a new one.

codecov[bot] commented 6 years ago

Codecov Report

Merging #902 into master will decrease coverage by 0.11%. The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #902      +/-   ##
==========================================
- Coverage   48.53%   48.42%   -0.12%     
==========================================
  Files          84       84              
  Lines        7837     7859      +22     
==========================================
+ Hits         3804     3806       +2     
- Misses       3722     3743      +21     
+ Partials      311      310       -1
Impacted Files Coverage Δ
pkg/callable/backend/ssh/script.go 0.96% <0%> (-0.26%) :arrow_down:
pkg/types/spec.go 60.17% <0%> (+1.76%) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update b5de550...e281bd8. Read the comment docs.