{"action":"created","issue":{"url":"https://api.github.com/repos/ungleich/cdist/issues/680","repository_url":"https://api.github.com/repos/ungleich/cdist","labels_url":"https://api.github.com/repos/ungleich/cdist/issues/680/labels{/name}","comments_url":"https://api.github.com/repos/ungleich/cdist/issues/680/comments","events_url":"https://api.github.com/repos/ungleich/cdist/issues/680/events","html_url":"https://github.com/ungleich/cdist/issues/680","id":343233452,"node_id":"MDU6SXNzdWUzNDMyMzM0NTI=","number":680,"title":"Allow custom SSH options","user":{"login":"matthijskooijman","id":194491,"node_id":"MDQ6VXNlcjE5NDQ5MQ==","avatar_url":"https://avatars3.githubusercontent.com/u/194491?v=4","gravatar_id":"","url":"https://api.github.com/users/matthijskooijman","html_url":"https://github.com/matthijskooijman","followers_url":"https://api.github.com/users/matthijskooijman/followers","following_url":"https://api.github.com/users/matthijskooijman/following{/other_user}","gists_url":"https://api.github.com/users/matthijskooijman/gists{/gist_id}","starred_url":"https://api.github.com/users/matthijskooijman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matthijskooijman/subscriptions","organizations_url":"https://api.github.com/users/matthijskooijman/orgs","repos_url":"https://api.github.com/users/matthijskooijman/repos","events_url":"https://api.github.com/users/matthijskooijman/events{/privacy}","received_events_url":"https://api.github.com/users/matthijskooijman/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-07-20T20:11:48Z","updated_at":"2018-07-20T20:21:04Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"To customize the way cdist connects to my target hosts, it would be nice if there was an easier way to pass options to the `ssh` and `scp` commands. In particular, I'm looking for `-o ProxyJump=some_server` to allow using a jump host for connections.\r\n\r\nCurrently, this can be supported using the `--remote-exec` and `--remote-copy` options (or their associated config file equivalents). However, this has a number of downsides:\r\n - This requires duplicating all default options as well: https://github.com/ungleich/cdist/blob/1f2b7c84c2c56b69267321174971794da2d1b986/cdist/__init__.py#L46-L47\r\n - This requires separately specifying the ssh and scp commands.\r\n - This breaks support for using a control connection, which only works when cdists constructs the command (and it seems that without a control connection, cdist becomes unusably slow for me...)\r\n\r\nTo circumvent these, a new commandline (and config) option could be useful. E.g. `--ssh-option ProxyJump=some_server`, or `--ssh-argument -oProxyJump=some_server` could help here, if cdist would keep the existing logic for generating the commands, but just adds some extra options. Just adding `-o` options to SSH is *probably* enough (and `-o` is certainly supported by both ssh and scp).\r\n\r\nHow does that sound?"},"comment":{"url":"https://api.github.com/repos/ungleich/cdist/issues/comments/406716318","html_url":"https://github.com/ungleich/cdist/issues/680#issuecomment-406716318","issue_url":"https://api.github.com/repos/ungleich/cdist/issues/680","id":406716318,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNjcxNjMxOA==","user":{"login":"matthijskooijman","id":194491,"node_id":"MDQ6VXNlcjE5NDQ5MQ==","avatar_url":"https://avatars3.githubusercontent.com/u/194491?v=4","gravatar_id":"","url":"https://api.github.com/users/matthijskooijman","html_url":"https://github.com/matthijskooijman","followers_url":"https://api.github.com/users/matthijskooijman/followers","following_url":"https://api.github.com/users/matthijskooijman/following{/other_user}","gists_url":"https://api.github.com/users/matthijskooijman/gists{/gist_id}","starred_url":"https://api.github.com/users/matthijskooijman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matthijskooijman/subscriptions","organizations_url":"https://api.github.com/users/matthijskooijman/orgs","repos_url":"https://api.github.com/users/matthijskooijman/repos","events_url":"https://api.github.com/users/matthijskooijman/events{/privacy}","received_events_url":"https://api.github.com/users/matthijskooijman/received_events","type":"User","site_admin":false},"created_at":"2018-07-20T20:21:04Z","updated_at":"2018-07-20T20:21:04Z","author_association":"CONTRIBUTOR","body":"I fiddled around with ~/.ssh/config, which can be made to work, but requires me to keep a list of hostnames in my homedir, while I really want to keep everything on our cdist-fork (so things can be more easily shared between different people in our project, and project-specific config does not leak out of the project repo).\r\n\r\nAlso, I'd like to be able to easily enable and disable these options (e.g. I'll need the proxyjump for hosts that are already deployed to the production network, but when initially configuring them, I'll have direct network access). Being able to (not) pass a single `--ssh-option`, or even nicer, a `-g` option to point cdist to the right config file would help here, none of which works with ~/.ssh/config."}}
{"actor":{"display_login":"matthijskooijman"}}