1
0
Fork 0
mirror of https://github.com/docker/login-action.git synced 2025-03-31 12:10:05 +02:00
This commit is contained in:
eine 2022-03-02 19:05:06 +01:00 committed by GitHub
commit ba83e5f124
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 13 additions and 4 deletions

9
dist/index.js generated vendored
View file

@ -282,8 +282,13 @@ async function loginECR(registry, username, password) {
input: Buffer.from(regData.password)
})
.then(res => {
if (res.stderr.length > 0 && res.exitCode != 0) {
throw new Error(res.stderr.trim());
if (res.stderr.length > 0) {
if (res.exitCode != 0) {
throw new Error(res.stderr.trim());
}
else {
core.warning(res.stderr);
}
}
core.info('Login Succeeded!');
});

View file

@ -43,8 +43,12 @@ export async function loginStandard(registry: string, username: string, password
input: Buffer.from(password)
})
.then(res => {
if (res.stderr.length > 0 && res.exitCode != 0) {
throw new Error(res.stderr.trim());
if (res.stderr.length > 0) {
if (res.exitCode != 0) {
throw new Error(res.stderr.trim());
} else {
core.warning(res.stderr);
}
}
core.info(`Login Succeeded!`);
});