-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.drone.yml
55 lines (51 loc) · 1.23 KB
/
.drone.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
---
kind: pipeline
type: docker
name: isudo.ru CI/CD
steps:
- name: Install
pull: always
image: python:3.8-slim
environment:
XDG_CACHE_HOME: .cache
POETRY_VIRTUALENVS_PATH: .cache
CONF_PY:
from_secret: CONF_PY
commands:
- pip3 install poetry
- poetry install
- echo "$CONF_PY" > conf.py
- name: Test
pull: always
image: python:3.8-slim
environment:
XDG_CACHE_HOME: .cache
POETRY_VIRTUALENVS_PATH: .cache
commands:
- pip3 install poetry
- poetry run pytest
- name: Build
pull: always
image: python:3.8-slim
environment:
XDG_CACHE_HOME: .cache
POETRY_VIRTUALENVS_PATH: .cache
commands:
- pip3 install poetry
- poetry run python cli.py build
- name: Deploy
pull: always
image: python:3.8-slim
environment:
XDG_CACHE_HOME: .cache
POETRY_VIRTUALENVS_PATH: .cache
AWS_ACCESS_KEY_ID:
from_secret: AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY:
from_secret: AWS_SECRET_ACCESS_KEY
commands:
- pip3 install poetry
- poetry run python cli.py deploy --region=ru-central1 --endpoint=https://storage.yandexcloud.net
when:
branch:
- master