Skip to content

Commit

Permalink
Add support for full SSH paths
Browse files Browse the repository at this point in the history
For cases where the SSH command on the $PATH might not be ideal, allow
the user to override this with a full path in the config.

Addresses #10
  • Loading branch information
Joshua Boniface committed Apr 29, 2021
1 parent 107092d commit 1a0e9f0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
3 changes: 2 additions & 1 deletion rffmpeg.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@
"remote_hosts": o_config["rffmpeg"]["remote"]["hosts"],
"remote_user": o_config["rffmpeg"]["remote"]["user"],
"remote_args": o_config["rffmpeg"]["remote"]["args"],
"ssh_command": o_config["rffmpeg"]["commands"]["ssh"],
"pre_commands": o_config["rffmpeg"]["commands"]["pre"],
"ffmpeg_command": o_config["rffmpeg"]["commands"]["ffmpeg"],
"ffprobe_command": o_config["rffmpeg"]["commands"]["ffprobe"],
Expand Down Expand Up @@ -208,7 +209,7 @@ def setup_remote_command(target_host):
rffmpeg_ffmpeg_command = list()

# Add SSH component
rffmpeg_ssh_command.append("ssh")
rffmpeg_ssh_command.append(config["ssh_command"])
rffmpeg_ssh_command.append("-q")

# Set our connection timeouts, in case one of several remote machines is offline
Expand Down
4 changes: 4 additions & 0 deletions rffmpeg.yml.sample
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ rffmpeg:

# Remote command configuration
commands:
# By default rffmpeg uses $PATH to find the "ssh" program; use this option to set a full path
# to an SSH binary if you want to override the default.
ssh: "ssh"

# A YAML list of prefixes to the ffmpeg command (e.g. sudo, nice, etc.),
# one line per space-separated command element.
pre:
Expand Down

0 comments on commit 1a0e9f0

Please sign in to comment.