Skip to content

Commit

Permalink
feat: kano build can now push to a private registry. [skip build][ski…
Browse files Browse the repository at this point in the history
…p doc]
  • Loading branch information
robinbourianes-kalisio committed Apr 15, 2021
1 parent 4d8ff3e commit 08c8ba1
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions build/kano.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,10 @@ cd kano
# Create the archive to be merged
tar cvf kano.tgz -C ../../configs/kano .
# Build the image
docker build --pull --force-rm --build-arg TAG=$KANO_TAG --build-arg SUBDOMAIN --build-arg NODE_APP_INSTANCE --build-arg NODE_ENV -f dockerfile -t localhost:5000/kano:$KANO_TAG .
docker push localhost:5000/kano:$KANO_TAG
docker build --pull --force-rm --build-arg TAG=$KANO_TAG --build-arg SUBDOMAIN --build-arg NODE_APP_INSTANCE --build-arg NODE_ENV -f dockerfile -t $KANO_IMAGE:$KANO_TAG .
if [ -n "$REGISTRY_USERNAME" ]; then
# Extract registry url from image
REGISTRY_URL=$(echo $KANO_IMAGE | awk -F '/' '{ print $1 }')
docker login "$REGISTRY_URL" -u "$REGISTRY_USERNAME" -p "$REGISTRY_PASSWORD"
fi
docker push $KANO_IMAGE:$KANO_TAG

0 comments on commit 08c8ba1

Please sign in to comment.