Skip to content

Conversation

@taylor-s-dean
Copy link
Contributor

@taylor-s-dean taylor-s-dean commented Nov 6, 2019

Description

ssh._extra args are currently ignored and never actually appended to the rsh arg. This PR addresses this issue (#402 which is closed despite never being properly resolved)

Testing

Configuration:

settings {
        logfile = "/var/log/lsyncd/lsyncd.log",
        statusFile = "/var/log/lsyncd/lsyncd.status",
        insist = true
}

sync {
        default.rsyncssh,
        source = "<source>",
        host = "<host>",
        targetdir = "<destination>",
        excludeFrom = "/etc/lsyncd/lsyncd.exclude",
        delay = 5,
        rsync = {
                verbose = true,
                inplace = true,
                _extra = {
                        "--info=progress2"
                }
        },
        ssh = {
                identityFile = "/home/taylor/.ssh/id_ed25519",
                options = {
                        User = "taylor",
                        StrictHostKeyChecking = "no",
                        Compression = "no",
                        Cipher = "[email protected]"
                },
                _extra = {
                        "-T",
                        "-c",
                        "[email protected]"
                }
        }
}

Results of runing lsyncd before changes:

/usr/bin/rsync --exclude-from=- --delete --ignore-errors -slvt --info=progress2 --inplace --rsh=ssh -i /home/taylor/.ssh/id_ed25519 -o Compression=no -o User=taylor -o StrictHostKeyChecking=no -o [email protected] -r <source> <host>:<destination>

ssh -i /home/taylor/.ssh/id_ed25519 -o Compression=no -o User=taylor -o StrictHostKeyChecking=no -o [email protected] <host> rsync --server -svltre.iLsfxC

Results of running lsyncd after changes:

/usr/bin/rsync --exclude-from=- --delete --ignore-errors -lvts --info=progress2 --inplace --rsh=ssh -i /home/taylor/.ssh/id_ed25519 -o StrictHostKeyChecking=no -o Compression=no -o [email protected] -o User=taylor -T -c [email protected] -r <source> <host>:<destination>

ssh -i /home/taylor/.ssh/id_ed25519 -o StrictHostKeyChecking=no -o Compression=no -o [email protected] -o User=taylor -T -c [email protected] <host> rsync --server -svltre.iLsfxC

ssh._extra args are currently ignored and never actually appended
to the rsh arg. This PR addresses this issue (lsyncd#402 which is closed
despite never being properly resolved)
@poelzi poelzi closed this in bb247e0 Dec 8, 2021
@poelzi poelzi merged commit bb247e0 into lsyncd:master Dec 8, 2021
@poelzi
Copy link
Member

poelzi commented Dec 9, 2021

thanks, merged

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants