Compare commits

...

5 commits
main ... V0.7.4

Author SHA1 Message Date
fe4e3428c0 Podman build container
All checks were successful
ci/woodpecker/tag/test Pipeline was successful
ci/woodpecker/tag/build Pipeline was successful
2025-06-26 15:40:30 +02:00
04edafde2c Fix
All checks were successful
ci/woodpecker/tag/test Pipeline was successful
ci/woodpecker/tag/build Pipeline was successful
2025-06-25 16:23:04 +02:00
75bf44479f Cache
Some checks failed
ci/woodpecker/tag/test Pipeline was successful
ci/woodpecker/tag/build Pipeline failed
2025-06-25 16:20:59 +02:00
4e0c3c2f3c Rename package, print version
All checks were successful
ci/woodpecker/tag/test Pipeline was successful
ci/woodpecker/tag/build Pipeline was successful
2025-06-25 16:14:38 +02:00
680bab41c4 Add tag
All checks were successful
ci/woodpecker/tag/test Pipeline was successful
ci/woodpecker/tag/build Pipeline was successful
2025-06-25 15:38:24 +02:00
7 changed files with 41 additions and 27 deletions

View file

@ -6,21 +6,7 @@ depends_on:
- test
steps:
container_build_release_push:
#image: docker.io/maltegrosse/woodpecker-buildah:0.0.12
image: code.philo.ydns.eu/philorg/woodpecker-buildah
settings:
registry: code.philo.ydns.eu
repository: philorg/test-woodpecker-python
tags: ${CI_COMMIT_SHA}
architectures: amd64
context: Containerfile
username:
from_secret: registry_username
password:
from_secret: registry_password
sync:
python_sync:
image: code.philo.ydns.eu/philorg/uv
volumes:
- uv-cache:/uv-cache
@ -30,7 +16,7 @@ steps:
commands:
- uv sync
build:
python_build:
image: code.philo.ydns.eu/philorg/uv
volumes:
- uv-cache:/uv-cache
@ -41,7 +27,7 @@ steps:
- uv build --wheel
- uv cache prune --ci
push_python:
python_publish:
image: code.philo.ydns.eu/philorg/uv
environment:
OWNER: philorg
@ -51,3 +37,26 @@ steps:
commands:
- uv publish --publish-url $REGISTRY_URL/api/packages/$OWNER/pypi --token $REGISTRY_TOKEN dist/*.whl
failure: ignore
container_build_publish:
image: quay.io/podman/stable:latest
# Caution: This image is built daily. It might fill up your image store quickly.
#pull: true
volumes:
- containers:/var/lib/containers
# Fill in the trusted checkbox in Woodpecker's settings as well
privileged: true
environment:
registry: code.philo.ydns.eu
org: philorg
container_name: test-woodpecker-python
registry_token:
from_secret: registry_token
commands:
# Login at the registry
- podman login -u __token__ --password $registry_token $registry
# Build the container image
- podman build --volume=/var/lib/containers:/var/lib/containers --tag $registry/$org/$container_name:latest --tag $registry/$org/$container_name:$CI_COMMIT_TAG .
# Push the image
- podman push $registry/$org/$container_name:latest
- podman push $registry/$org/$container_name:$CI_COMMIT_TAG

View file

@ -3,6 +3,7 @@
FROM docker.io/python:alpine
COPY . /app
ENV UV_LINK_MODE=copy
WORKDIR /app
@ -11,6 +12,7 @@ RUN \
--mount=from=code.philo.ydns.eu/philorg/uv,source=/usr/local/bin/uv,target=/bin/uv \
--mount=from=code.philo.ydns.eu/philorg/uv,source=/usr/lib/libpcre2-8.so.0,target=/usr/lib/libpcre2-8.so.0 \
--mount=from=code.philo.ydns.eu/philorg/uv,source=/usr/bin/git,target=/usr/bin/git \
--mount=type=cache,target=/root/.cache/uv \
uv pip install --system .
ENTRYPOINT ["foo"]

View file

@ -1,5 +1,5 @@
[project]
name = "test-woodpecker-ci"
name = "test-woodpecker"
dynamic = ["version"]
description = "Sandbox for Woodpecker CI"
readme = "README.md"
@ -7,7 +7,7 @@ requires-python = ">=3.13"
dependencies = []
[project.scripts]
foo = "test_woodpecker_ci.main:main"
foo = "test_woodpecker.main:main"
[build-system]
requires = ["hatchling", "uv-dynamic-versioning"]
@ -17,7 +17,7 @@ build-backend = "hatchling.build"
source = "uv-dynamic-versioning"
[tool.hatch.build.targets.wheel]
packages = ["src/test_woodpecker_ci"]
packages = ["src/test_woodpecker"]
[dependency-groups]
dev = ["dunamai>=1.24.1", "httpx>=0.28.1", "pytest>=8.4.1"]

View file

@ -0,0 +1,9 @@
from test_woodpecker import __version__
def main():
print(f"Hello from test-woodpecker {__version__}!")
if __name__ == "__main__":
main()

View file

@ -1,6 +0,0 @@
def main():
print("Hello from test-woodpecker-ci!")
if __name__ == "__main__":
main()

2
uv.lock generated
View file

@ -153,7 +153,7 @@ wheels = [
]
[[package]]
name = "test-woodpecker-ci"
name = "test-woodpecker"
source = { editable = "." }
[package.dev-dependencies]