HomePhorge

(#6541) Use the same filebucket for backup and restore
e31369aaf5a1Unpublished

Unpublished Commit · Learn More

Repository Importing: This repository is still importing.

Description

(#6541) Use the same filebucket for backup and restore

The acceptance test for #6541 was using `puppet filebucket backup -l
/dev/null` to cause a 0-length file to be created in the agent's
filebucket, and then attempting to retrieve the file using:

file { ...:
  content => '{md5}d41d8cd98f00b204e9800998ecf8427e'

However, this was failing because the former was writing to
${vardir}/bucket, while the latter was trying to read from
${vardir}/clientbucket, and failing to find the 0-length file.

This test reported a false positive earlier, because the test was
reusing the clientbucket from a previous test. Now that the acceptance
tests clean the agent vardir, it uncovered this problem.

This commit changes the test to create a 0-length file, then
overwrites it, causing the old file to be backed up into the
clientbucket.

Details

Event Timeline

Josh Cooper <josh@puppetlabs.com> committed rPUe31369aaf5a1: (#6541) Use the same filebucket for backup and restore (authored by Josh Cooper <josh@puppetlabs.com>).Jan 24 2012, 6:17 PM