From 84163517c600ff64e0d6ece4ecba40a8aeb52d73 Mon Sep 17 00:00:00 2001 From: Fabio Berger Date: Mon, 14 Jan 2019 15:24:00 +0100 Subject: Add additional check to make sure user was added to our DockerHub org --- packages/monorepo-scripts/src/publish.ts | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'packages/monorepo-scripts/src/publish.ts') diff --git a/packages/monorepo-scripts/src/publish.ts b/packages/monorepo-scripts/src/publish.ts index 4a22df544..105d87dcd 100644 --- a/packages/monorepo-scripts/src/publish.ts +++ b/packages/monorepo-scripts/src/publish.ts @@ -22,7 +22,6 @@ import { utils } from './utils/utils'; const NPM_NAMESPACE = '@0x/'; const TODAYS_TIMESTAMP = moment().unix(); -const DOCKER_ORG = '0xorg'; async function confirmAsync(message: string): Promise { prompt.start(); @@ -130,13 +129,13 @@ async function publishImagesToDockerHubAsync(allUpdatedPackages: Package[]): Pro // Tag the docker image with the latest version const version = pkg.packageJson.version; logUtils.log(`Tagging '${dockerHubRepo}' docker image with version ${version}...`); - await execAsync(`docker tag ${dockerHubRepo} ${DOCKER_ORG}/${dockerHubRepo}:${version}`); - await execAsync(`docker tag ${dockerHubRepo} ${DOCKER_ORG}/${dockerHubRepo}:latest`); + await execAsync(`docker tag ${dockerHubRepo} ${configs.DOCKER_HUB_ORG}/${dockerHubRepo}:${version}`); + await execAsync(`docker tag ${dockerHubRepo} ${configs.DOCKER_HUB_ORG}/${dockerHubRepo}:latest`); // Publish to DockerHub logUtils.log(`Pushing '${dockerHubRepo}' docker image to DockerHub...`); - await execAsync(`docker push ${DOCKER_ORG}/${dockerHubRepo}:${version}`); - await execAsync(`docker push ${DOCKER_ORG}/${dockerHubRepo}:latest`); + await execAsync(`docker push ${configs.DOCKER_HUB_ORG}/${dockerHubRepo}:${version}`); + await execAsync(`docker push ${configs.DOCKER_HUB_ORG}/${dockerHubRepo}:latest`); } } -- cgit