Override "/srv/ftp.debian.org/scripts/override/";
QueueBuild "/srv/incoming.debian.org/buildd/";
UrgencyLog "/srv/release.debian.org/britney/input/urgencies/";
+ TempPath "/srv/ftp.debian.org/tmp/";
Queue
{
Byhand "/srv/ftp.debian.org/queue/byhand/";
Header "contents";
Root "/srv/ftp.debian.org/test/";
}
-
-TempPath
-{
- TempPath "/srv/ftp.debian.org/tmp/";
-};
"""
# Lets check if from_file is in the directory we expect it to be in
- if not os.path.abspath(from_file).startswith(Cnf["TempPath::TempPath"]):
- print "Will not accept transitions file outside of %s" % (Cnf["TempPath::TempPath"])
+ if not os.path.abspath(from_file).startswith(Cnf["Dir::TempPath"]):
+ print "Will not accept transitions file outside of %s" % (Cnf["Dir::TempPath"])
sys.exit(3)
if Options["sudo"]:
sudo-ed script and would be unreadable if it has default mkstemp mode
"""
- (fd, path) = tempfile.mkstemp("", "transitions", Cnf["TempPath::TempPath"])
+ (fd, path) = tempfile.mkstemp("", "transitions", Cnf["Dir::TempPath"])
os.chmod(path, 0644)
f = open(path, "w")
yaml.dump(transitions, f, default_flow_style=False)
(Cnf["Dinstall::Reject::ReleaseTransitions"]))
sys.exit(1)
# Also check if our temp directory is defined and existant
- temppath = Cnf.get("TempPath::TempPath", "")
+ temppath = Cnf.get("Dir::TempPath", "")
if temppath == "":
- utils.warn("TempPath::TempPath not defined")
+ utils.warn("Dir::TempPath not defined")
sys.exit(1)
if not os.path.exists(temppath):
utils.warn("Temporary path %s not found." %
- (Cnf["TempPath::TempPath"]))
+ (Cnf["Dir::TempPath"]))
sys.exit(1)
if Options["import"]:
self.holding_dir = Config()["Dir::Queue::Holding"]
# ftptrainees haven't access to holding, use a temp directory instead
if not os.access(self.holding_dir, os.W_OK):
- self.holding_dir = Config()["TempPath::TempPath"]
+ self.holding_dir = Config()["Dir::TempPath"]
def copy_to_holding(self, filename):
base_filename = os.path.basename(filename)