Merge pull request #6940 from lmskater/fix-proxy

[Jenkins][ci skip] Fix proxy address to jenkins config
This commit is contained in:
minggo 2014-05-30 13:47:08 +08:00
commit 50fc1e23c5
4 changed files with 12 additions and 4 deletions

View File

@ -8,7 +8,9 @@ import sys
import traceback
import urllib2
http_proxy = os.environ['HTTP_PROXY']
http_proxy = ''
if(os.environ.has_key('HTTP_PROXY')):
http_proxy = os.environ['HTTP_PROXY']
proxyDict = {'http':http_proxy,'https':http_proxy}
def main():

View File

@ -8,7 +8,9 @@ import sys
import traceback
from jenkinsapi.jenkins import Jenkins
http_proxy = os.environ['HTTP_PROXY']
http_proxy = ''
if(os.environ.has_key('HTTP_PROXY')):
http_proxy = os.environ['HTTP_PROXY']
proxyDict = {'http':http_proxy,'https':http_proxy}
def check_queue_build(action, pr_num, statuses_url):

View File

@ -5,7 +5,9 @@ import jenkinsapi
from jenkinsapi.jenkins import Jenkins
from jenkinsapi.constants import STATUS_SUCCESS
payload_str = os.environ['payload']
http_proxy = ''
if(os.environ.has_key('HTTP_PROXY')):
http_proxy = os.environ['HTTP_PROXY']
payload_str = payload_str.decode('utf-8','ignore')
#parse to json obj
payload = json.loads(payload_str)

View File

@ -61,7 +61,9 @@ def check_current_3rd_libs(branch):
current_file = current_files[i]
copy(current_file, backup_file)
http_proxy = os.environ['HTTP_PROXY']
http_proxy = ''
if(os.environ.has_key('HTTP_PROXY')):
http_proxy = os.environ['HTTP_PROXY']
proxyDict = {'http':http_proxy,'https':http_proxy}
def main():
#get payload from os env