mirror of
				https://github.com/optim-enterprises-bv/kubernetes.git
				synced 2025-11-04 04:08:16 +00:00 
			
		
		
		
	Reorder process shutdown in test-cmd and exit immediately
This commit is contained in:
		@@ -174,7 +174,7 @@ fi
 | 
				
			|||||||
function stop-proxy()
 | 
					function stop-proxy()
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
  [[ -n "${PROXY_PORT-}" ]] && kube::log::status "Stopping proxy on port ${PROXY_PORT}"
 | 
					  [[ -n "${PROXY_PORT-}" ]] && kube::log::status "Stopping proxy on port ${PROXY_PORT}"
 | 
				
			||||||
  [[ -n "${PROXY_PID-}" ]] && kill "${PROXY_PID}" 1>&2 2>/dev/null
 | 
					  [[ -n "${PROXY_PID-}" ]] && kill -9 "${PROXY_PID}" 1>&2 2>/dev/null
 | 
				
			||||||
  [[ -n "${PROXY_PORT_FILE-}" ]] && rm -f "${PROXY_PORT_FILE}"
 | 
					  [[ -n "${PROXY_PORT_FILE-}" ]] && rm -f "${PROXY_PORT_FILE}"
 | 
				
			||||||
  PROXY_PID=
 | 
					  PROXY_PID=
 | 
				
			||||||
  PROXY_PORT=
 | 
					  PROXY_PORT=
 | 
				
			||||||
@@ -223,10 +223,10 @@ function start-proxy()
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
function cleanup()
 | 
					function cleanup()
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
  [[ -n "${APISERVER_PID-}" ]] && kill "${APISERVER_PID}" 1>&2 2>/dev/null
 | 
					 | 
				
			||||||
  [[ -n "${CTLRMGR_PID-}" ]] && kill "${CTLRMGR_PID}" 1>&2 2>/dev/null
 | 
					 | 
				
			||||||
  [[ -n "${KUBELET_PID-}" ]] && kill "${KUBELET_PID}" 1>&2 2>/dev/null
 | 
					 | 
				
			||||||
  stop-proxy
 | 
					  stop-proxy
 | 
				
			||||||
 | 
					  [[ -n "${CTLRMGR_PID-}" ]] && kill -9 "${CTLRMGR_PID}" 1>&2 2>/dev/null
 | 
				
			||||||
 | 
					  [[ -n "${KUBELET_PID-}" ]] && kill -9 "${KUBELET_PID}" 1>&2 2>/dev/null
 | 
				
			||||||
 | 
					  [[ -n "${APISERVER_PID-}" ]] && kill -9 "${APISERVER_PID}" 1>&2 2>/dev/null
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  kube::etcd::cleanup
 | 
					  kube::etcd::cleanup
 | 
				
			||||||
  rm -rf "${KUBE_TEMP}"
 | 
					  rm -rf "${KUBE_TEMP}"
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user