81 lines
1.5 KiB
YAML
81 lines
1.5 KiB
YAML
---
|
|
kind: pipeline
|
|
type: kubernetes
|
|
|
|
#type: docker
|
|
|
|
clone:
|
|
#disable: true
|
|
depth: 1
|
|
|
|
name: deploy develop and staging
|
|
|
|
platform:
|
|
os: linux
|
|
arch: amd64
|
|
|
|
trigger:
|
|
branch:
|
|
- master
|
|
event:
|
|
- push
|
|
|
|
steps:
|
|
|
|
- name: pre build image
|
|
image: harbor.1sept.ru/drone/drone-kaniko
|
|
settings:
|
|
registry: harbor.1sept.ru
|
|
repo: drone/drone-kaniko
|
|
cache: false
|
|
tags:
|
|
- git-${DRONE_COMMIT_SHA:0:7}
|
|
- drone-${DRONE_BUILD_NUMBER}
|
|
- 1.23.2-debug
|
|
username:
|
|
from_secret: harbor-username
|
|
password:
|
|
from_secret: harbor-password
|
|
|
|
- name: test image
|
|
image: harbor.1sept.ru/drone/drone-kaniko:1.23.2-debug
|
|
settings:
|
|
registry: harbor.1sept.ru
|
|
repo: drone/drone-kaniko
|
|
cache: false
|
|
tags:
|
|
- test
|
|
username:
|
|
from_secret: harbor-username
|
|
password:
|
|
from_secret: harbor-password
|
|
|
|
- name: build image
|
|
image: harbor.1sept.ru/drone/drone-kaniko
|
|
settings:
|
|
registry: harbor.1sept.ru
|
|
repo: drone/drone-kaniko
|
|
cache: false
|
|
tags:
|
|
- git-${DRONE_COMMIT_SHA:0:7}
|
|
- drone-${DRONE_BUILD_NUMBER}
|
|
- 1.23.2-debug
|
|
- latest
|
|
username:
|
|
from_secret: harbor-username
|
|
password:
|
|
from_secret: harbor-password
|
|
|
|
image_pull_secrets:
|
|
- dockerconfig
|
|
# Такая кнопка нужна
|
|
# POST /api/repos/{owner}/{repo}/builds/{build}/promote?target={target}
|
|
#
|
|
# Read more: https://docs.drone.io/api/builds/build_promote/
|
|
|
|
---
|
|
kind: signature
|
|
hmac: dffa37945bf257b1523893d31bd28e05e9113cf43b913a58154009e5ee815f9a
|
|
|
|
...
|