25 lines
579 B
YAML
25 lines
579 B
YAML
|
---
|
||
|
kind: pipeline
|
||
|
type: kubernetes
|
||
|
name: Build image
|
||
|
|
||
|
image_pull_secrets:
|
||
|
- dockerconfig
|
||
|
|
||
|
trigger:
|
||
|
ref:
|
||
|
- refs/heads/testing
|
||
|
- refs/heads/main
|
||
|
- refs/tags/*
|
||
|
|
||
|
steps:
|
||
|
- name: Build docker image
|
||
|
image: gcr.io/kaniko-project/executor:debug
|
||
|
environment:
|
||
|
DOCKER_AUTH:
|
||
|
from_secret: dockerconfig
|
||
|
IMAGE_PREFIX: mxfox.ru/mlops/mlflow
|
||
|
commands:
|
||
|
- echo $${DOCKER_AUTH} > /kaniko/.docker/config.json
|
||
|
- /kaniko/executor --context `pwd` --destination "$${IMAGE_PREFIX}:${CI_COMMIT_BRANCH}-${CI_BUILD_NUMBER}-${DRONE_COMMIT_SHA:0:10}"
|