new file: .gitea/workflows/publish.yml
Publish Python package to PyPI / publish (push) Failing after 6s

new file:   .gitignore
new file:   LICENSE
modified:   pyproject.toml
This commit is contained in:
Sven Luthi committed 2026-10-26 18:54:31 +01:00
1 parent 62b809db95
commit 2489e1465b
4 files changed
+80 -2

No files matched your search

+44
View File
@@ -0,0 +1,44 @@
name: Publish Python package to PyPI
on:
push:
tags:
- "v*"
jobs:
publish:
runs-on: self-hosted
steps:
- name: Check out repository
uses: https://github.com/actions/checkout@v4
- name: Set up Python
uses: https://github.com/actions/setup-python@v5
with:
python-version: "3.x"
- name: Verify tag matches package version
run: |
TAG="${GITHUB_REF_NAME}"
VERSION="$(python -c "import tomllib; print(tomllib.load(open('pyproject.toml','rb'))['project']['version'])")"
if [ "$TAG" != "v$VERSION" ]; then
echo "::error::Tag ${TAG} does not match package version v${VERSION}"
exit 1
fi
- name: Install build tools
run: python -m pip install --upgrade build twine
- name: Build package
run: python -m build
- name: Check package
run: python -m twine check dist/*
- name: Publish to PyPI
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
TWINE_NON_INTERACTIVE: "1"
run: python -m twine upload dist/*
+6
View File
@@ -0,0 +1,6 @@
__pycache__/
*.py[cod]
build/
dist/
*.egg-info/
.venv/
+21
View File
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2026 Sven Luthi
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+9 -2
View File
@@ -1,5 +1,5 @@
[build-system]
requires = ["setuptools>=61"]
requires = ["setuptools>=77"]
build-backend = "setuptools.build_meta"
[project]
@@ -8,7 +8,9 @@ version = "1.0.0"
description = "NetBox DNS (netbox-plugin-dns) DNS-01 authenticator plugin for Certbot"
readme = "README.md"
requires-python = ">=3.9"
license = { text = "Apache-2.0" }
license = "MIT"
license-files = ["LICENSE"]
authors = [{ name = "Sven Luthi", email = "dev@sven.luethi.co" }]
keywords = ["certbot", "acme", "letsencrypt", "netbox", "dns", "dns-01"]
classifiers = [
"Development Status :: 5 - Production/Stable",
@@ -16,6 +18,7 @@ classifiers = [
"Intended Audience :: System Administrators",
"Operating System :: POSIX :: Linux",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Security",
]
@@ -25,6 +28,10 @@ dependencies = [
"urllib3>=1.26",
]
[project.urls]
Homepage = "https://git.luethi.co/sven/certbot-dns-netbox"
Repository = "https://git.luethi.co/sven/certbot-dns-netbox.git"
[project.entry-points."certbot.plugins"]
dns-netbox = "certbot_dns_netbox.dns_netbox:Authenticator"