File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -153,8 +153,11 @@ def _get_entrypoint(self, container_type):
153153 """
154154 Return the kubernetes "container command" to be sent off to the scheduler.
155155 """
156- entrypoint = ['/bin/sh' , '-c' ]
156+ entrypoint = []
157157 release = self .release_set .filter (failed = False ).latest ()
158+ if release is not None and release .build is not None :
159+ if release .build .procfile and container_type in release .build .procfile :
160+ entrypoint = ['/bin/sh' , '-c' ]
158161 if self ._get_stack (release ) == "buildpack" :
159162 if container_type in release .build .procfile :
160163 entrypoint = [container_type ]
Original file line number Diff line number Diff line change @@ -589,7 +589,7 @@ def test_run_command_good(self, mock_requests):
589589 response = self .client .post (url , body )
590590 self .assertEqual (response .status_code , 200 , response .data )
591591 app = App .objects .get (id = app_id )
592- self .assertEqual (app ._get_entrypoint ('cmd' ), ['/bin/sh' , '-c' ])
592+ self .assertEqual (app ._get_entrypoint ('cmd' ), [])
593593
594594 # procfile workflow
595595 build .sha = 'somereallylongsha'
You can’t perform that action at this time.
0 commit comments