2020-08-20 14:40:33 +00:00
|
|
|
import * as core from '@actions/core';
|
|
|
|
|
|
|
|
export interface Inputs {
|
|
|
|
registry: string;
|
|
|
|
username: string;
|
|
|
|
password: string;
|
2021-12-20 09:59:11 +00:00
|
|
|
ecr: string;
|
2021-06-22 08:39:55 +00:00
|
|
|
logout: boolean;
|
2025-01-23 16:07:51 +00:00
|
|
|
httpCodesToRetry: string[];
|
|
|
|
maxAttempts: number;
|
|
|
|
retryTimeout: number;
|
2020-08-20 14:40:33 +00:00
|
|
|
}
|
|
|
|
|
2020-10-09 10:30:45 +00:00
|
|
|
export function getInputs(): Inputs {
|
2020-08-20 14:40:33 +00:00
|
|
|
return {
|
|
|
|
registry: core.getInput('registry'),
|
2020-10-20 12:41:56 +00:00
|
|
|
username: core.getInput('username'),
|
|
|
|
password: core.getInput('password'),
|
2021-12-20 09:59:11 +00:00
|
|
|
ecr: core.getInput('ecr'),
|
2025-01-23 01:27:56 +00:00
|
|
|
logout: core.getBooleanInput('logout'),
|
2025-01-23 16:07:51 +00:00
|
|
|
httpCodesToRetry: core.getInput('http-codes-to-retry').split(','),
|
|
|
|
maxAttempts: Number.parseInt(core.getInput('max-attempts')),
|
|
|
|
retryTimeout: Number.parseInt(core.getInput('retry-timeout'))
|
2020-08-20 14:40:33 +00:00
|
|
|
};
|
|
|
|
}
|