semantic-release-docker
Advanced tools
Comparing version 2.0.1 to 2.0.2
const execa = require('execa') | ||
module.exports = async (pluginConfig, { logger }) => { | ||
for (const envVar of ['DOCKER_EMAIL', 'DOCKER_USERNAME', 'DOCKER_PASSWORD']) { | ||
for (const envVar of ['DOCKER_USERNAME', 'DOCKER_PASSWORD']) { | ||
if (!process.env[envVar]) { | ||
@@ -10,12 +10,5 @@ throw new Error(`Environment variable ${envVar} is not set`) | ||
try { | ||
await execa( | ||
'docker', | ||
[ | ||
'login', | ||
'-e=' + process.env.DOCKER_EMAIL, | ||
'-u=' + process.env.DOCKER_USERNAME, | ||
'-p=' + process.env.DOCKER_PASSWORD, | ||
], | ||
{ stdio: 'inherit' } | ||
) | ||
await execa('docker', ['login', '-u=' + process.env.DOCKER_USERNAME, '-p=' + process.env.DOCKER_PASSWORD], { | ||
stdio: 'inherit', | ||
}) | ||
} catch (err) { | ||
@@ -22,0 +15,0 @@ throw new Error('docker login failed') |
{ | ||
"name": "semantic-release-docker", | ||
"description": "Set of semantic-release plugins to publish to docker hub", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"engines": { | ||
@@ -6,0 +6,0 @@ "node": ">=8" |
@@ -30,4 +30,3 @@ # semantic-release-docker | ||
Your credentials have to be configured with the environment variables `DOCKER_USERNAME`, `DOCKER_EMAIL` and | ||
`DOCKER_PASSWORD`. | ||
Your credentials have to be configured with the environment variables `DOCKER_USERNAME` and `DOCKER_PASSWORD`. | ||
@@ -34,0 +33,0 @@ In addition, you need to specify the name of the image as the `name` setting. |
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 4 instances in 1 package
6688
29
67
6