This repository has been archived on 2023-06-30. You can view files and clone it, but cannot push or open issues or pull requests.
2chBackAPI/.drone.yml

38 lines
920 B
YAML
Raw Normal View History

2022-10-17 20:06:09 +10:00
---
kind: pipeline
type: exec
name: default
platform:
os: linux
arch: amd64
clone:
# убрано так как сейчас не тестим ничего предварительно а сразу тянем в директорию
disable: true
steps:
- name: pull into the folduh
commands:
- cd /usr/share/$DRONE_REPO_NAME
- git pull
- name: build
2022-10-18 13:06:27 +10:00
environment:
2022-10-18 13:07:30 +10:00
DOTNET_CLI_TELEMETRY_OPTOUT: 1
2022-10-17 20:06:09 +10:00
commands:
- cd /usr/share/$DRONE_REPO_NAME
- dotnet build
2022-10-18 12:41:36 +10:00
- name: recreate dist folder
2022-10-17 20:06:09 +10:00
commands:
2022-10-18 12:41:36 +10:00
- rm -rf /usr/share/$DRONE_REPO_NAME/dist
2022-10-17 20:06:09 +10:00
- mkdir -p /usr/share/$DRONE_REPO_NAME/dist
2022-10-18 12:38:58 +10:00
- mv -f /usr/share/$DRONE_REPO_NAME/bin/Debug/net6.0/* /usr/share/$DRONE_REPO_NAME/dist
2022-10-18 12:36:17 +10:00
- name: docker-compose-rebuild
commands:
- cd /usr/share/$DRONE_REPO_NAME
- docker compose up -d --build
2022-10-17 20:06:09 +10:00
- name: cleanup
commands:
2022-10-18 12:36:17 +10:00
- rm -rf /usr/share/$DRONE_REPO_NAME/bin /usr/share/$DRONE_REPO_NAME/obj