Compare commits

10 Commits

Author SHA1 Message Date
d3594bb33b Update README.md
All checks were successful
Tests / test (3.10) (push) Successful in 15s
Tests / test (3.11) (push) Successful in 15s
Tests / test (3.12) (push) Successful in 16s
Tests / test (3.13) (push) Successful in 15s
Tests / test (3.8) (push) Successful in 19s
Tests / test (3.9) (push) Successful in 19s
2025-11-24 13:55:32 +01:00
dbbb0a7dd4 Merge pull request 'ci: 👷 Add test workflow' (#3) from ci/test into main
All checks were successful
Tests / test (3.10) (push) Successful in 15s
Tests / test (3.11) (push) Successful in 16s
Tests / test (3.12) (push) Successful in 16s
Tests / test (3.13) (push) Successful in 15s
Tests / test (3.8) (push) Successful in 19s
Tests / test (3.9) (push) Successful in 16s
Reviewed-on: #3
2025-11-24 13:43:59 +01:00
880a2a04ad ci: Rename test workflow steps
All checks were successful
Tests / test (3.8) (pull_request) Successful in 18s
Tests / test (3.9) (pull_request) Successful in 15s
Tests / test (3.10) (pull_request) Successful in 15s
Tests / test (3.11) (pull_request) Successful in 15s
Tests / test (3.12) (pull_request) Successful in 16s
Tests / test (3.13) (pull_request) Successful in 16s
2025-11-24 13:42:12 +01:00
88fd47b3d2 ci: 👷 Add test workflow
All checks were successful
Tests / test (3.10) (pull_request) Successful in 22s
Tests / test (3.11) (pull_request) Successful in 23s
Tests / test (3.12) (pull_request) Successful in 22s
Tests / test (3.13) (pull_request) Successful in 15s
Tests / test (3.8) (pull_request) Successful in 26s
Tests / test (3.9) (pull_request) Successful in 21s
2025-11-24 13:37:19 +01:00
83fb4460bc Merge pull request 'ci: 👷 Add deployment workflow' (#2) from ci/deploy into main
All checks were successful
Build and Publish Release / build-and-publish (release) Successful in 23s
Reviewed-on: #2
2025-11-24 10:06:44 +01:00
ab399e740a ci: 👷 Add deployment workflow
All checks were successful
Build and Publish Release / build-and-publish (release) Successful in 49s
2025-11-24 10:02:56 +01:00
2aebaba299 README.md aktualisiert 2025-11-23 21:50:20 +01:00
2a4b4609fc Update README.md 2025-11-21 08:34:51 +01:00
6d758d8d97 Support Python 3.8+ 2025-11-20 05:27:50 +01:00
095c8e75d4 Remove legacy build tools 2025-11-20 05:25:55 +01:00
9 changed files with 1458 additions and 63 deletions

View File

@@ -0,0 +1,71 @@
name: Build and Publish Release
on:
release:
types: [published]
jobs:
build-and-publish:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: https://git.hogertz.eu/actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd
- name: Set up Python
uses: https://git.hogertz.eu/actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c
with:
python-version: '3.13'
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Extract version from release tag
id: get_version
run: |
# Remove 'v' prefix if present (e.g., v1.0.0 -> 1.0.0)
VERSION=${GITHUB_REF#refs/tags/}
VERSION=${VERSION#v}
echo "version=$VERSION" >> $GITHUB_OUTPUT
echo "Extracted version: $VERSION"
- name: Update version in pyproject.toml
run: |
VERSION="${{ steps.get_version.outputs.version }}"
sed -i "s/^version = .*/version = \"$VERSION\"/" pyproject.toml
echo "Updated pyproject.toml to version $VERSION"
cat pyproject.toml | grep "^version"
- name: Install build dependencies
run: |
uv sync --extra build
- name: Build package
run: |
uv run python -m build
- name: Create .pypirc
run: |
cat > ~/.pypirc << EOF
[distutils]
index-servers = gitea
[gitea]
repository = https://git.hogertz.eu/api/packages/hendrik-hog/pypi
username = ${{ secrets.USERNAME }}
password = ${{ secrets.PAT }}
EOF
chmod 600 ~/.pypirc
- name: Publish to Gitea PyPI
run: |
uv run python -m twine upload --repository gitea dist/*
- name: Commit version update
run: |
git config --local user.email "action@gitea.local"
git config --local user.name "Gitea Actions"
git add pyproject.toml
git diff --staged --quiet || git commit -m "chore: bump version to ${{ steps.get_version.outputs.version }}"
git push origin HEAD:main || echo "No changes to push or push failed"

36
.gitea/workflows/test.yml Normal file
View File

@@ -0,0 +1,36 @@
name: Tests
on:
pull_request:
push:
branches:
- main
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12', '3.13']
steps:
- name: Checkout code
uses: https://git.hogertz.eu/actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd
- name: Set up Python
uses: https://git.hogertz.eu/actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c
with:
python-version: ${{ matrix.python-version }}
- name: Install uv
run: |
curl -LsSf https://astral.sh/uv/install.sh | sh
echo "$HOME/.cargo/bin" >> $GITHUB_PATH
- name: Install dependencies
run: |
uv sync --extra dev
- name: Run tests
run: |
uv run pytest

3
.gitignore vendored
View File

@@ -3,3 +3,6 @@ corenetworks-credentials.ini
.python-version
**.pyc
certbot-test
*.egg-info
build
dist

View File

@@ -1,12 +1,16 @@
# certbot-dns-corenetworks
![Python Version](https://img.shields.io/badge/python-3.8%20%7C%203.9%20%7C%203.10%20%7C%203.11%20%7C%203.12%20%7C%203.13%20%7C%203.14-blue)
![Test Status](https://git.hogertz.eu/hendrik-hog/certbot-dns-corenetworks/actions/workflows/test.yml/badge.svg)
![Release Status](https://git.hogertz.eu/hendrik-hog/certbot-dns-corenetworks/actions/workflows/release.yml/badge.svg)
Core Networks DNS Authenticator plugin for Certbot
This plugin automates the process of completing a `dns-01` challenge by creating, and subsequently removing, TXT records using the Core Networks beta API.
## Requirements
- Python >= 3.10
- Python >= 3.8
- certbot >= 2.0.0
## Configuration of Core Networks
@@ -17,6 +21,12 @@ See [Core Networks API Documentation](https://beta.api.core-networks.de/doc/) fo
## Installation
### From Gitea PyPI
```bash
pip3 install certbot-dns-corenetworks --index-url https://git.hogertz.eu/api/packages/hendrik-hog/pypi/simple
```
### From source
```bash
@@ -98,10 +108,6 @@ pytest
pytest --cov=certbot_dns_corenetworks --cov-report=html
```
## License
Apache License 2.0 - See LICENSE.txt for details
## Credits
Original author: Masin Al-Dujaili

View File

@@ -20,7 +20,7 @@ class AuthenticatorTest(test_util.TempDirTestCase):
path = os.path.join(self.tempdir, "file.ini")
dns_test_common.write(
{"corenetworks_login": LOGIN, "corenetworks_password": PASSWORD}, path
{"corenetworks_username": LOGIN, "corenetworks_password": PASSWORD}, path
)
self.config = mock.MagicMock(

View File

@@ -7,7 +7,7 @@ name = "certbot-dns-corenetworks"
version = "1.0.0"
description = "Core Networks DNS Authenticator plugin for Certbot"
readme = "README.md"
requires-python = ">=3.10"
requires-python = ">=3.8"
license = { text = "Apache License 2.0" }
authors = [{ name = "Hendrik Hogertz", email = "info@hogertz.eu" }]
keywords = ["certbot", "dns", "corenetworks", "letsencrypt"]
@@ -19,10 +19,13 @@ classifiers = [
"Operating System :: POSIX :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Security",
"Topic :: System :: Installation/Setup",
@@ -34,6 +37,7 @@ dependencies = ["certbot>=2.0.0", "acme>=2.0.0", "requests>=2.20.0"]
[project.optional-dependencies]
dev = ["pytest>=7.0.0", "pytest-cov>=4.0.0"]
build = ["build>=1.0.0", "twine>=4.0.0"]
[project.urls]
Homepage = "https://git.hogertz.eu/hendrik-hog/certbot-dns-corenetworks"

View File

@@ -1,2 +0,0 @@
[bdist_wheel]
universal = 1

View File

@@ -1,9 +0,0 @@
"""Minimal setup.py for backward compatibility.
Modern installation should use pyproject.toml with pip >= 21.3
"""
from setuptools import setup
# All configuration is now in pyproject.toml
setup()

1372
uv.lock generated

File diff suppressed because it is too large Load Diff