File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -1067,7 +1067,7 @@ def _ecr_login_if_needed(boto_session, image):
10671067 ecr_url = auth ["authorizationData" ][0 ]["proxyEndpoint" ]
10681068
10691069 cmd = "docker login -u AWS -p %s %s" % (token , ecr_url )
1070- subprocess .check_output (cmd , shell = True )
1070+ subprocess .check_output (cmd . split () )
10711071
10721072 return True
10731073
@@ -1081,5 +1081,5 @@ def _pull_image(image):
10811081 pull_image_command = ("docker pull %s" % image ).strip ()
10821082 logger .info ("docker command: %s" , pull_image_command )
10831083
1084- subprocess .check_output (pull_image_command , shell = True )
1084+ subprocess .check_output (pull_image_command . split () )
10851085 logger .info ("image pulled: %s" , image )
Original file line number Diff line number Diff line change @@ -765,7 +765,7 @@ def test_ecr_login_needed(check_output):
765765 "docker login -u AWS -p %s https://520713654638.dkr.ecr.us-east-1.amazonaws.com" % token
766766 )
767767
768- check_output .assert_called_with (expected_command , shell = True )
768+ check_output .assert_called_with (expected_command . split () )
769769 session_mock .client ("ecr" ).get_authorization_token .assert_called_with (
770770 registryIds = ["520713654638" ]
771771 )
@@ -781,7 +781,7 @@ def test_pull_image(check_output):
781781
782782 expected_command = "docker pull %s" % image
783783
784- check_output .assert_called_once_with (expected_command , shell = True )
784+ check_output .assert_called_once_with (expected_command . split () )
785785
786786
787787def test__aws_credentials_with_long_lived_credentials ():
You can’t perform that action at this time.
0 commit comments