use docker to build image

This commit is contained in:
Torma Kristóf 2020-08-06 22:56:23 +02:00
parent f1d9789e43
commit 84ff3b4c05
Signed by: tormakris
GPG Key ID: DC83C4F2C41B1047

View File

@ -3,19 +3,16 @@ type: docker
name: default
steps:
- name: kaniko
image: banzaicloud/drone-kaniko
settings:
registry: registry.kmlabz.com
repo: birbnetes/${DRONE_REPO_NAME}
username:
from_secret: DOCKER_USERNAME
password:
from_secret: DOCKER_PASSWORD
tags:
- latest
- ${DRONE_BUILD_NUMBER}
- name: docker
image: docker
volumes:
- /var/run/docker.sock:/var/run/docker.sock
commands:
- echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin registry.kmlabz.com
- docker build -t registry.kmlabz.com/$DRONE_REPO .
- docker build -t registry.kmlabz.com/$DRONE_REPO:$DRONE_BUILD_NUMBER .
- docker push registry.kmlabz.com/$DRONE_REPO
- docker push registry.kmlabz.com/$DRONE_REPO:$DRONE_BUILD_NUMBER
- name: ms-teams
image: kuperiu/drone-teams