Skip to content

Instantly share code, notes, and snippets.

@int128
Created July 29, 2016 15:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save int128/113875e6f6093ef92948a944f5dadab6 to your computer and use it in GitHub Desktop.
Save int128/113875e6f6093ef92948a944f5dadab6 to your computer and use it in GitHub Desktop.

Instructions to reproduce bug int128/gradle-ssh-plugin#253

2016-07-29 15:16:25.283 WARN  Host key checking is off. It may be vulnerable to man-in-the-middle attacks.
2016-07-29 15:16:26.584 INFO  Connected to sandbox [sandbox:22]
2016-07-29 15:16:27.119 INFO  Started command sandbox#0: mkdir -vp /tmp/hoge/foo/bar
2016-07-29 15:16:27.360 INFO  Success command sandbox#0: mkdir -vp /tmp/hoge/foo/bar
2016-07-29 15:16:27.587 ERROR Error: groovy.lang.MissingMethodException: No signature of method: org.hidetake.groovy.ssh.session.transfe
r.SftpRemove$Trait$Helper$_remove_closure1$_closure2$_closure4.call() is applicable for argument types: (org.codehaus.groovy.runtime.GSt
ringImpl) values: [/tmp/hoge/foo/bar]
Possible solutions: any(), any(), any(groovy.lang.Closure), each(groovy.lang.Closure), any(groovy.lang.Closure), each(groovy.lang.Closur
e)
2016-07-29 15:16:27.590 INFO  Run with -s or --stacktrace option to get the stack trace

docker run -d -e authorized_key="$(cat ~/.ssh/id_rsa.pub)" --name sandbox int128/
integration-test-box:latest
docker run -it --rm --link sandbox:sandbox --read-only -v ~/.ssh:/root/.ssh int128/groovy-ssh -i -e "
ssh.remotes {
sandbox {
user='tester'
host='sandbox'
knownHosts=allowAnyHosts
identity=new File('~/.ssh/id_rsa')
}
}
ssh.run{
session(ssh.remotes.sandbox) {
execute('mkdir -vp /tmp/hoge/foo/bar')
remove('/tmp/hoge')
}
}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment