ai-base-image/.drone.yml

40 lines
1.1 KiB
YAML

kind: pipeline
type: docker
name: default
steps:
- name: docker
image: docker
volumes:
- name: docker_sock
path: /var/run/docker.sock
environment:
DOCKER_USERNAME:
from_secret: DOCKER_USERNAME
DOCKER_PASSWORD:
from_secret: DOCKER_PASSWORD
commands:
- echo "$DOCKER_PASSWORD" | docker login --username "$DOCKER_USERNAME" --password-stdin registry.kmlabz.com
- echo "$DOCKERHUB_PASSWORD" | docker login --username "$DOCKERHUB_USERNAME" --password-stdin
- docker build -t registry.kmlabz.com/$DRONE_REPO .
- docker build -t registry.kmlabz.com/$DRONE_REPO:$DRONE_BUILD_NUMBER .
- docker build -t $DRONE_REPO .
- docker build -t $DRONE_REPO:$DRONE_BUILD_NUMBER .
- docker push registry.kmlabz.com/$DRONE_REPO
- docker push registry.kmlabz.com/$DRONE_REPO:$DRONE_BUILD_NUMBER
- docker push $DRONE_REPO
- docker push $DRONE_REPO:$DRONE_BUILD_NUMBER
- name: ms-teams
image: kuperiu/drone-teams
settings:
webhook:
from_secret: TEAMS_WEBHOOK
when:
status: [ failure ]
volumes:
- name: docker_sock
host:
path: /var/run/docker.sock