30
30
pass
31
31
32
32
33
- version = VERSION = __version__ = '1.5.2 '
33
+ version = VERSION = __version__ = '1.6.0 '
34
34
35
35
COLOR = True
36
36
@@ -228,6 +228,7 @@ def main(*argv, **kwargs):
228
228
enterprise = parser .add_argument_group ('======================== Enterprise ========================' )
229
229
enterprise .add_argument ('--slug' , '-r' , default = os .getenv ("CODECOV_SLUG" ), help = "Specify repository slug for Enterprise ex. owner/repo" )
230
230
enterprise .add_argument ('--url' , '-u' , default = os .getenv ("CODECOV_URL" , "https://codecov.io" ), help = "Your Codecov endpoint" )
231
+ enterprise .add_argument ('--cacert' , default = os .getenv ("CODECOV_CACERT" , os .getenv ("CURL_CA_BUNDLE" )), help = "Certificate pem bundle used to verify with your Codecov instance" )
231
232
232
233
debugging = parser .add_argument_group ('======================== Debugging ========================' )
233
234
debugging .add_argument ('--dump' , action = "store_true" , help = "Dump collected data and do not send to Codecov" )
@@ -586,6 +587,7 @@ def main(*argv, **kwargs):
586
587
try :
587
588
write (' Pinging Codecov...' )
588
589
res = requests .post ('%s/upload/v3?%s' % (codecov .url , urlargs ),
590
+ verify = codecov .cacert ,
589
591
headers = {'Accept' : 'text/plain' })
590
592
if res .status_code in (400 , 406 ):
591
593
raise Exception (res .text )
@@ -609,6 +611,7 @@ def main(*argv, **kwargs):
609
611
write (' Uploading to Codecov...' )
610
612
# just incase, try traditional upload
611
613
res = requests .post ('%s/upload/v2?%s' % (codecov .url , urlargs ),
614
+ verify = codecov .cacert ,
612
615
data = '\n ' .join ((reports , s3 .reason if s3 else '' , s3 .text if s3 else '' )),
613
616
headers = {"Accept" : "text/plain" })
614
617
if res .status_code < 500 :
0 commit comments