summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorValentin David <valentin.david@codethink.co.uk>2018-08-07 16:19:47 +0200
committerTristan Van Berkom <tristan.van.berkom@gmail.com>2018-08-12 05:57:44 +0000
commit9a0259b9e47302930a6cc114122227b995481027 (patch)
treea6d81e4805de4fc2c888f6434c48af4ee023ef95
parente8a3297b3d0d0652a91ee84b335e8d41545dbb7b (diff)
downloadbuildstream-9a0259b9e47302930a6cc114122227b995481027.tar.gz
buildstream/plugins/sources/remote.py: Make staging deterministic.
-rw-r--r--buildstream/plugins/sources/remote.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/buildstream/plugins/sources/remote.py b/buildstream/plugins/sources/remote.py
index ad4cdab8b..ea0e612c2 100644
--- a/buildstream/plugins/sources/remote.py
+++ b/buildstream/plugins/sources/remote.py
@@ -49,6 +49,7 @@ remote - stage files from remote urls
"""
import os
+import stat
from buildstream import SourceError, utils
from ._downloadablefilesource import DownloadableFileSource
@@ -75,6 +76,7 @@ class RemoteSource(DownloadableFileSource):
dest = os.path.join(directory, self.filename)
with self.timed_activity("Staging remote file to {}".format(dest)):
utils.safe_copy(self._get_mirror_file(), dest)
+ os.chmod(dest, stat.S_IRUSR | stat.S_IWUSR | stat.S_IRGRP | stat.S_IROTH)
def setup():