Merge lp:~gesha/linaro-license-protection/staging-upload-paths into lp:~linaro-automation/linaro-license-protection/trunk

Proposed by Georgy Redkozubov
Status: Merged
Approved by: Stevan Radaković
Approved revision: 119
Merged at revision: 120
Proposed branch: lp:~gesha/linaro-license-protection/staging-upload-paths
Merge into: lp:~linaro-automation/linaro-license-protection/trunk
Diff against target: 31 lines (+7/-0)
1 file modified
scripts/publish_to_snapshots.py (+7/-0)
To merge this branch: bzr merge lp:~gesha/linaro-license-protection/staging-upload-paths
Reviewer Review Type Date Requested Status
Stevan Radaković Approve
Review via email: mp+121263@code.launchpad.net

Description of the change

This branch adds publishing to staging.snapshots.linaro.org server into correct paths.

To post a comment you must log in.
Revision history for this message
Stevan Radaković (stevanr) wrote :

Looks good.
Approve +1.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'scripts/publish_to_snapshots.py'
2--- scripts/publish_to_snapshots.py 2012-08-22 19:33:22 +0000
3+++ scripts/publish_to_snapshots.py 2012-08-24 19:15:24 +0000
4@@ -10,6 +10,8 @@
5
6 uploads_path = '/srv/snapshots.linaro.org/uploads/'
7 target_path = '/srv/snapshots.linaro.org/www/'
8+staging_uploads_path = '/srv/staging.snapshots.linaro.org/uploads/'
9+staging_target_path = '/srv/staging.snapshots.linaro.org/www/'
10 PASS = 0
11 FAIL = 1
12 acceptable_job_types = [
13@@ -324,6 +326,8 @@
14
15
16 def main():
17+ global uploads_path
18+ global target_path
19 argument_parser = setup_parser()
20 publisher = SnapshotsPublisher(argument_parser)
21 args = argument_parser.parse_args()
22@@ -331,6 +335,9 @@
23 publisher.validate_args(args)
24 except PublisherArgumentException as exception:
25 argument_parser.error(exception.message)
26+ if args.staging:
27+ uploads_path = staging_uploads_path
28+ target_path = staging_target_path
29 try:
30 build_dir_path, target_dir_path = publisher.validate_paths(
31 args, uploads_path, target_path)

Subscribers

People subscribed via source and target branches