generators/docker-cli.js
function loginToAws(region, accountId, username, password) {
    const commandLine = `docker login --username AWS --password ${password} https://${accountId}.dkr.ecr.${region}.amazonaws.com`;
    return new Promise(
        (resolve, reject) =>
            command(commandLine, (err, stdout) => {
                if (err) {
                    reject(err);
                }
                resolve(stdout);
            }),
        { silent: true }
    );
}
function loginToAws(region, accountId, username, password) {
    const commandLine = `docker login --username AWS --password ${password} https://${accountId}.dkr.ecr.${region}.amazonaws.com`;
    return new Promise(
        (resolve, reject) =>
            command(commandLine, (err, stdout) => {
                if (err) {
                    reject(err);
                }
                resolve(stdout);
            }),
        { silent: true }
    );
}
function loginToAws ( region , accountId , username , password ) { const commandLine = ` ${ password } ${ accountId } ${ region } ` ; return new Promise ( ( resolve , reject ) => command ( commandLine , ( err , stdout ) => { if ( err ) { reject ( err ) ; } resolve ( stdout ) ; } ) , { silent : true } ) ; }
Log docker to AWS.
@param region
@param accountId
@param username
@param password
@returns {Promise}
Log docker to AWS .