Status: Closed (View Workflow)
- is related to
JENKINS-13126 Create empty directories on remote server
Yes, of course. We used to use rsync and it works fine. But we wanted to switch over to a more integrated configuration experience: Configure the target hosts in the jenkins configuration and refer to this configuration from a job., use include patterns as in every other place within the build jobs and so on. So this is not a real blocker, but would make life a lot easier. Not to mention that rsync is not available on Windows hosts, in contrast to jenkins and its plugins.
then it would be best for the author or someone who is willing to contribue to allow extra params to pass to scp. the -r switch should be sending empty directories. check the source of the plugin to see if this is part of the default parameters, in the worst case you can add it yourself.
Hi Ken, thanks for your helpful comments, I really appreciate your input!
I've already had a look at the source to find the exact source fragment involved in this, but I was not successful on the first run. Maybe I find more time later. In the meantime I would appreciate any hints on which source files to start for this feature.
I have a solution for this - it will just take a week or two for me to fit it into my backlog.
In the mean time can you use the decades old trick of zero length hidden files? i.e. touch .keep in any leaf directory that yo want to be present on the target machine. (you can even use find in the Exec command to remove them afterwards if you need the dirs to be completely empty)
Alternatively keep zipping until a new version is released.
Code changed in jenkins
[FIXED JENKINS-13126] [FIXED JENKINS-13831] Option to create empty directories
Code changed in jenkins
[FIXED JENKINS-13831] Option to create empty directories
For your information, all publish-over-ssh component type JENKINS issues related to the Publish Over SSH plugin have been transferred to Github: https://github.com/jenkinsci/publish-over-ssh-plugin/issues
Here is the direct link to this issue in Github: https://github.com/jenkinsci/publish-over-ssh-plugin/issues/216
And here is the link to a search for related issues: https://github.com/jenkinsci/publish-over-ssh-plugin/issues?q=%22JENKINS-13831%22
(Note: this is an automated bulk comment)
Sorry for escalating this, but for our company this is urgently needed:
If you're using an application framework which relies on certain directories being there although they may be empty and try to deploy your application with this publisher you end up with a corrupt deployment. For this reason we need to zip all the contents before publishing and unzip afterwards.