Merge lp:~mwhudson/launchpad/puller-proxy-argh into lp:launchpad/db-devel

Proposed by Michael Hudson-Doyle
Status: Merged
Approved by: Brad Crittenden
Approved revision: no longer in the source branch.
Merged at revision: not available
Proposed branch: lp:~mwhudson/launchpad/puller-proxy-argh
Merge into: lp:launchpad/db-devel
Diff against target: 20 lines
1 file modified
scripts/mirror-branch.py (+3/-0)
To merge this branch: bzr merge lp:~mwhudson/launchpad/puller-proxy-argh
Reviewer Review Type Date Requested Status
Brad Crittenden (community) release-critical Approve
Tim Penhey (community) Approve
Review via email: mp+12327@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Michael Hudson-Doyle (mwhudson) wrote :

Hi,

Literally a few minutes before rollout I realized that we had a problem with the puller: pulling MIRRORED branches must have $http_proxy set, but pulling IMPORTED branches must not. This was previously handled by setting or not the environment variable in the crontab but now we only have one crontab entry for pulling all branches so this won't work. The option I went for is a hack in the mirror-branch.py script. It's been working on production so far, so let's make sure a re-rollout doesn't obliterate it :)

Cheers,
mwh

Revision history for this message
Tim Penhey (thumper) wrote :

On Thu, 24 Sep 2009 17:05:23 Michael Hudson wrote:
> Michael Hudson has proposed merging
> lp:~mwhudson/launchpad/puller-proxy-argh into lp:launchpad.
>
> Requested reviews:
> Canonical Launchpad Engineering (launchpad)
>
>
> Hi,
>
> Literally a few minutes before rollout I realized that we had a problem
> with the puller: pulling MIRRORED branches must have $http_proxy set, but
> pulling IMPORTED branches must not. This was previously handled by
> setting or not the environment variable in the crontab but now we only
> have one crontab entry for pulling all branches so this won't work. The
> option I went for is a hack in the mirror-branch.py script. It's been
> working on production so far, so let's make sure a re-rollout doesn't
> obliterate it :)
>
>
> Cheers,
> mwh
>

Looks reasonable :-)

  merge approved

review: Approve
Revision history for this message
Brad Crittenden (bac) :
review: Approve (release-critical)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'scripts/mirror-branch.py'
--- scripts/mirror-branch.py 2009-07-23 02:33:14 +0000
+++ scripts/mirror-branch.py 2009-09-24 05:05:22 +0000
@@ -32,6 +32,7 @@
3232
33import _pythonpath33import _pythonpath
34from optparse import OptionParser34from optparse import OptionParser
35import os
35import resource36import resource
36import sys37import sys
3738
@@ -81,6 +82,8 @@
81 branch_type_name, oops_prefix, default_stacked_on_url) = arguments82 branch_type_name, oops_prefix, default_stacked_on_url) = arguments
8283
83 branch_type = BranchType.items[branch_type_name]84 branch_type = BranchType.items[branch_type_name]
85 if branch_type == BranchType.IMPORTED and 'http_proxy' in os.environ:
86 del os.environ['http_proxy']
84 section_name = 'supermirror_%s_puller' % branch_type_map[branch_type]87 section_name = 'supermirror_%s_puller' % branch_type_map[branch_type]
85 globalErrorUtility.configure(section_name)88 globalErrorUtility.configure(section_name)
86 shut_up_deprecation_warning()89 shut_up_deprecation_warning()

Subscribers

People subscribed via source and target branches

to status/vote changes: