Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the support of local scripts #31

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

honglonglong
Copy link

Add the support of local scripts, that could be run on local server before rsync to remote server.

This is required by my project because when target server got lower version of openSSH, and it's impossible to upgrade the target server, so adopt a local script feature to run below before sync files.
echo -e "Host xxx.xxx.xxx.xxx\n KexAlgorithms +diffie-hellman-group1-sha1" >> ~/.ssh/config

@mjwwit
Copy link
Collaborator

mjwwit commented Jul 11, 2022

I'm terribly sorry for the late response... This PR must have slipped my attention.

Wouldn't it be better to allow a custom SSH config to be passed? That seems like a more direct approach to solving your problem.

@honglonglong
Copy link
Author

Hi @mjwwit, Thank you for the reply. Could you explain more on how to pass a custom SSH config?

@mjwwit
Copy link
Collaborator

mjwwit commented Jul 14, 2022

There currently isn't a way to pass custom config, but the ability to do this would in my opinion be a better solution to your problem than your local script.
There are several ways one could implement this. You could allow the user to specify the path to a file which contains the custom SSH config. You could also allow the user to specify the custom config within the pipeline. Of course, having it both ways is also possible.

@honglonglong
Copy link
Author

There currently isn't a way to pass custom config, but the ability to do this would in my opinion be a better solution to your problem than your local script. There are several ways one could implement this. You could allow the user to specify the path to a file which contains the custom SSH config. You could also allow the user to specify the custom config within the pipeline. Of course, having it both ways is also possible.

Thanks for the explanation. The custom config way is to put a file in the target server right? it seems difficult for my case, because I'm using docker for Drone CI, so I cannot put a custom config file into the target server.

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