Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build: publish Kapacitor sdk for UDFs on PyPi #2764

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
33 changes: 33 additions & 0 deletions .github/workflows/pypi-release.yml
@@ -0,0 +1,33 @@
name: Publish to PyPI
on:
push:
tags:
- 'v*'

jobs:
publish:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2

- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.11

- name: Install Poetry
run: pip install poetry

- name: Authenticate with PyPI
env:
POETRY_PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
run: |
poetry config pypi-token.pypi $POETRY_PYPI_TOKEN

- name: Build and publish
run: |
cd udf/agent/py
poetry build
poetry publish --no-interaction
2 changes: 2 additions & 0 deletions .gitignore
Expand Up @@ -12,6 +12,8 @@ kapacitor*.rpm
kapacitor*.deb
kapacitor*.tar
kapacitor*.zip
kapacitor*.tar.gz
kapacitor*.whl
*.pyc
*.test
/test-logs
Expand Down
1 change: 0 additions & 1 deletion udf/agent/py/kapacitor/udf/__init__.py
@@ -1 +0,0 @@
VERSION = ""
19 changes: 19 additions & 0 deletions udf/agent/py/pyproject.toml
@@ -0,0 +1,19 @@
[tool.poetry]
name = "kapacitor_udf"
version = "1.6.6"
description = "Kapacitor UDF Agent library"
authors = ["InfluxDB <support@influxdb.com>"]
maintainers = ["InfluxDB <support@influxdb.com>"]
homepage = "github.com/influxdata/kapacitor"
license = "MIT"
packages = [
{ include = "kapacitor" },
]

[tool.poetry.dependencies]
python = "^3.8"
protobuf = "3.18.3"

[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
23 changes: 0 additions & 23 deletions udf/agent/py/setup.py

This file was deleted.