Skip to content
This repository was archived by the owner on Jan 10, 2023. It is now read-only.

Fix for "sh: 'rsync' no such file or directory" on RHEL-like systems#43

Merged
bflad merged 1 commit intobflad:masterfrom
legal90:fix-rsync
Jan 23, 2015
Merged

Fix for "sh: 'rsync' no such file or directory" on RHEL-like systems#43
bflad merged 1 commit intobflad:masterfrom
legal90:fix-rsync

Conversation

@legal90
Copy link
Copy Markdown
Contributor

@legal90 legal90 commented Nov 11, 2014

The ark resource requires rsync package to be installed.

It fixes the next error (reproduced on "centos6" and "stash" cookbook version 3.12.1):

...
==> centos6: Mixlib::ShellOut::ShellCommandFailed
==> centos6: ------------------------------------
==> centos6: execute[unpack /var/chef/cache/stash-backup-client-1.5.0.zip] (/tmp/vagrant-chef-3/chef-solo-1/cookbooks/ark/providers/default.rb line 55) had an error: Mixlib::ShellOut::ShellCommandFailed: Expected process to exit with [0], but received '127'
==> centos6:
==> centos6: ---- Begin output of unzip -q -u -o /var/chef/cache/stash-backup-client-1.5.0.zip -d /tmp/d20141111-3706-192msdu && rsync -a /tmp/d20141111-3706-192msdu/*/ /opt/atlassian/stash-backup-client-1.5.0 && rm -rf /tmp/d20141111-3706-192msdu ----
==> centos6:
==> centos6: STDOUT:
==> centos6:
==> centos6: STDERR: sh: rsync: command not found
==> centos6:
==> centos6: ---- End output of unzip -q -u -o /var/chef/cache/stash-backup-client-1.5.0.zip -d /tmp/d20141111-3706-192msdu && rsync -a /tmp/d20141111-3706-192msdu/*/ /opt/atlassian/stash-backup-client-1.5.0 && rm -rf /tmp/d20141111-3706-192msdu ----
==> centos6:
==> centos6: Ran unzip -q -u -o /var/chef/cache/stash-backup-client-1.5.0.zip -d /tmp/d20141111-3706-192msdu && rsync -a /tmp/d20141111-3706-192msdu/*/ /opt/atlassian/stash-backup-client-1.5.0 && rm -rf /tmp/d20141111-3706-192msdu returned 127...

It is required by 'ark' resource.
Fixes "sh: 'rsync' no such file or directory" error on RHEL-like systems
@bflad
Copy link
Copy Markdown
Owner

bflad commented Jan 23, 2015

LGTM since rsync is available as package on supported platforms and https://supermarket.chef.io/cookbooks/rsync seems a little overkill since it only installs the package as well. Maybe in the future this can be an attribute that people can override to not install either rsync or unzip via package if they don't want.

bflad added a commit that referenced this pull request Jan 23, 2015
Fix for "sh: 'rsync' no such file or directory" on RHEL-like systems
@bflad bflad merged commit f66e00d into bflad:master Jan 23, 2015
@legal90 legal90 deleted the fix-rsync branch January 23, 2015 15:41
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants