mirror of
https://github.com/docker/login-action.git
synced 2024-11-17 17:45:39 +01: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 => {
|
||||
if (res.stderr.length > 0 && res.exitCode != 0) {
|
||||
let isRetriable: boolean
|
||||
isRetriable = res.stderr.endsWith("502 Bad Gateway")
|
||||
isRetriable = res.stderr.trim().endsWith("502 Bad Gateway")
|
||||
if (!isRetriable || (attempt >= attempts) {
|
||||
throw new Error(res.stderr.trim());
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user