mirror of
				https://github.com/docker/login-action.git
				synced 2025-10-31 10:10:09 +08:00 
			
		
		
		
	trim stderr for checking
Signed-off-by: Fedor Dikarev <fedor.dikarev@gmail.com>
This commit is contained in:
		
							parent
							
								
									8479e9040e
								
							
						
					
					
						commit
						162c32cf05
					
				| @ -51,7 +51,7 @@ export async function loginStandard(registry: string, username: string, password | |||||||
|     }).then(res => { |     }).then(res => { | ||||||
|       if (res.stderr.length > 0 && res.exitCode != 0) { |       if (res.stderr.length > 0 && res.exitCode != 0) { | ||||||
|         let isRetriable: boolean |         let isRetriable: boolean | ||||||
|         isRetriable = res.stderr.endsWith("502 Bad Gateway") |         isRetriable = res.stderr.trim().endsWith("502 Bad Gateway") | ||||||
|         if (!isRetriable || (attempt >= attempts) { |         if (!isRetriable || (attempt >= attempts) { | ||||||
|           throw new Error(res.stderr.trim()); |           throw new Error(res.stderr.trim()); | ||||||
|         } |         } | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Fedor Dikarev
						Fedor Dikarev