74 lines
2.3 KiB
YAML
74 lines
2.3 KiB
YAML
---
|
|
kind: pipeline
|
|
type: kubernetes
|
|
name: Nocr
|
|
|
|
clone:
|
|
disable: true
|
|
|
|
steps:
|
|
- name: clone
|
|
image: alpine/git
|
|
settings:
|
|
tags: true
|
|
commands:
|
|
- pwd
|
|
- git clone https://gitea.musk.fun/nocr/local-env
|
|
- cd local-env
|
|
- git submodule update --init --recursive
|
|
|
|
- name: nocr telegram listener build & push
|
|
image: plugins/docker
|
|
privileged: true
|
|
settings:
|
|
repo: hub.musk.fun/k8s/nocr/telegram_listener
|
|
registry: hub.musk.fun
|
|
context: ./local-env/telegram-listener
|
|
dockerfile: ./local-env/telegram-listener/src/Nocr.TelegramListener.Host/Dockerfile
|
|
tags: ["${DRONE_COMMIT_SHA:0:7}", "latest"]
|
|
username:
|
|
from_secret: hub_username
|
|
password:
|
|
from_secret: hub_password
|
|
|
|
- name: nocr telegram listener nuget package make & push
|
|
image: mcr.microsoft.com/dotnet/sdk:8.0
|
|
environment:
|
|
VERSION: ${DRONE_TAG}
|
|
NUGETAPIKEY:
|
|
from_secret: nuget_musk_api_key
|
|
commands:
|
|
- dotnet nuget add source --name musk https://gitea.musk.fun/api/packages/nocr/nuget/index.json
|
|
- dotnet pack ./local-env/telegram-listener/Nocr.TelegramListener.sln -o ./local-env/telegram-listener/bin
|
|
- dotnet nuget push ./local-env/telegram-listener/bin/*Contract*.nupkg --api-key $NUGETAPIKEY --source musk --skip-duplicate
|
|
|
|
- name: nocr text matcher build & push
|
|
image: plugins/docker
|
|
privileged: true
|
|
settings:
|
|
repo: hub.musk.fun/k8s/nocr/text_matcher
|
|
registry: hub.musk.fun
|
|
context: ./local-env/text-matcher
|
|
dockerfile: ./local-env/text-matcher/src/Nocr.TextMatcher.Host/Dockerfile
|
|
tags: ["${DRONE_COMMIT_SHA:0:7}", "latest"]
|
|
username:
|
|
from_secret: hub_username
|
|
password:
|
|
from_secret: hub_password
|
|
|
|
- name: nocr text matcher nuget package make & push
|
|
image: mcr.microsoft.com/dotnet/sdk:8.0
|
|
environment:
|
|
VERSION: ${DRONE_TAG}
|
|
NUGETAPIKEY:
|
|
from_secret: nuget_musk_api_key
|
|
commands:
|
|
- dotnet nuget add source --name musk https://gitea.musk.fun/api/packages/nocr/nuget/index.json
|
|
- dotnet pack ./local-env/text-matcher/Nocr.TextMatcher.sln -o ./local-env/text-matcher/bin
|
|
- dotnet nuget push ./local-env/text-matcher/bin/*Contract*.nupkg --api-key $NUGETAPIKEY --source musk --skip-duplicate
|
|
|
|
|
|
trigger:
|
|
event:
|
|
- tag
|