kojiwrapper: Call chmod recursively
Related: https://pagure.io/pungi/issue/932 Signed-off-by: Lubomír Sedlář <lsedlar@redhat.com>
This commit is contained in:
parent
71f2c61020
commit
663a07068e
@ -113,7 +113,7 @@ class KojiWrapper(object):
|
|||||||
command = "rm -f /var/lib/rpm/__db*; rm -rf /var/cache/yum/*; set -x; " + command
|
command = "rm -f /var/lib/rpm/__db*; rm -rf /var/cache/yum/*; set -x; " + command
|
||||||
|
|
||||||
if destdir:
|
if destdir:
|
||||||
command += " && chmod a+r %s" % shlex_quote(destdir)
|
command += " && chmod -R a+r %s" % shlex_quote(destdir)
|
||||||
cmd.append(command)
|
cmd.append(command)
|
||||||
|
|
||||||
return cmd
|
return cmd
|
||||||
|
@ -427,7 +427,7 @@ class RunrootKojiWrapperTest(KojiWrapperBaseTestCase):
|
|||||||
self.assertEqual(cmd[-2], 's390x')
|
self.assertEqual(cmd[-2], 's390x')
|
||||||
self.assertEqual(
|
self.assertEqual(
|
||||||
cmd[-1],
|
cmd[-1],
|
||||||
"rm -f /var/lib/rpm/__db*; rm -rf /var/cache/yum/*; set -x; /bin/echo '&' && chmod a+r '/output dir'"
|
"rm -f /var/lib/rpm/__db*; rm -rf /var/cache/yum/*; set -x; /bin/echo '&' && chmod -R a+r '/output dir'"
|
||||||
)
|
)
|
||||||
self.assertItemsEqual(cmd[3:-3],
|
self.assertItemsEqual(cmd[3:-3],
|
||||||
['--channel-override=chan', '--quiet', '--use-shell',
|
['--channel-override=chan', '--quiet', '--use-shell',
|
||||||
|
Loading…
Reference in New Issue
Block a user