2023-06-09 14:51:47 +02:00
|
|
|
kind: pipeline
|
|
|
|
type: docker
|
|
|
|
name: build_python_project
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: build
|
2023-06-13 07:34:55 +02:00
|
|
|
#image: python:3.11-bullseye
|
|
|
|
image: git.broillet.ch/mathieu/python3.11-bullseye-buildessential:1.0 # python3.11-bullseye image with build-essential & patchelf (apt) and nuitka(pip) installed
|
2023-06-09 14:51:47 +02:00
|
|
|
commands:
|
|
|
|
- pip install -r requirements.txt
|
2023-06-13 07:34:55 +02:00
|
|
|
# - apk add build-base patchelf # not needed with custom image
|
|
|
|
# - apt update -y # not needed with custom image
|
|
|
|
# - apt install build-essential patchelf -y # not needed with custom image
|
|
|
|
# - pip install nuitka # not needed with custom image
|
2023-06-09 23:10:30 +02:00
|
|
|
- python -m nuitka --onefile run.py --include-data-dir=./resources=resources --output-filename="ProxmoxDeploy${DRONE_TAG##v}"
|
2023-06-09 14:51:47 +02:00
|
|
|
- name: gitea_release
|
|
|
|
image: plugins/gitea-release
|
|
|
|
settings:
|
|
|
|
api_key:
|
|
|
|
from_secret: api_key
|
|
|
|
base_url: https://git.broillet.ch
|
2023-06-09 23:10:30 +02:00
|
|
|
files: ProxmoxDeploy${DRONE_TAG##v}
|
2023-06-09 14:51:47 +02:00
|
|
|
when:
|
|
|
|
event: tag
|