mirror of
https://github.com/NohamR/prometheus-qbittorrent-exporter.git
synced 2026-01-08 15:18:16 +00:00
Compare commits
11 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
75db331c55 | ||
|
|
d5c7cbc4a9 | ||
|
|
234a4cfffa | ||
|
|
4ad22a60da | ||
|
|
6c87b8eff9 | ||
|
|
e2a8508cae | ||
|
|
a6a4129daf | ||
|
|
723872bc15 | ||
|
|
cb78dd1fb7 | ||
|
|
8e08565d6e | ||
|
|
56a2792c2e |
59
.github/workflows/docker.yml
vendored
59
.github/workflows/docker.yml
vendored
@@ -11,52 +11,63 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: 'Checkout GitHub Action'
|
||||
uses: actions/checkout@v2
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Set up QEMU
|
||||
uses: docker/setup-qemu-action@v1
|
||||
uses: docker/setup-qemu-action@v3
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: docker/setup-buildx-action@v1
|
||||
uses: docker/setup-buildx-action@v3
|
||||
|
||||
- name: Extract branch name
|
||||
shell: bash
|
||||
run: |
|
||||
tag=${GITHUB_REF#refs/tags/}
|
||||
tag=${tag#refs/heads/}
|
||||
if echo $tag | grep -q -E "[0-9]+\.[0-9]+\.[0-9]+"; then
|
||||
tag="v$tag"
|
||||
fi
|
||||
echo "##[set-output name=tag;]$tag"
|
||||
id: extract_branch
|
||||
- name: Docker hub meta
|
||||
id: meta
|
||||
uses: docker/metadata-action@v5
|
||||
with:
|
||||
flavor: |
|
||||
latest=true
|
||||
tags: |
|
||||
type=semver,pattern=v{{version}}
|
||||
type=ref,event=branch
|
||||
type=sha
|
||||
images: ${{ github.actor }}/prometheus-qbittorrent-exporter
|
||||
|
||||
- name: Login to DockerHub
|
||||
uses: docker/login-action@v1
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
username: ${{ secrets.REGISTRY_USERNAME }}
|
||||
password: ${{ secrets.REGISTRY_PASSWORD }}
|
||||
|
||||
- name: Build and push docker to DockerHub
|
||||
uses: docker/build-push-action@v2
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
push: true
|
||||
platforms: linux/amd64,linux/arm64,linux/386
|
||||
tags: ${{ steps.meta.outputs.tags }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
|
||||
- name: GHCR Docker meta
|
||||
id: metaghcr
|
||||
uses: docker/metadata-action@v5
|
||||
with:
|
||||
flavor: |
|
||||
latest=true
|
||||
tags: |
|
||||
${{ secrets.REGISTRY_USERNAME }}/prometheus-qbittorrent-exporter:latest
|
||||
${{ secrets.REGISTRY_USERNAME }}/prometheus-qbittorrent-exporter:${{ steps.extract_branch.outputs.tag }}
|
||||
type=semver,pattern=v{{version}}
|
||||
type=ref,event=branch
|
||||
type=sha
|
||||
images: ghcr.io/${{ github.actor }}/prometheus-qbittorrent-exporter
|
||||
|
||||
- name: Login to Github Container Registry
|
||||
uses: docker/login-action@v1
|
||||
uses: docker/login-action@v3
|
||||
with:
|
||||
registry: ghcr.io
|
||||
username: ${{ secrets.REGISTRY_USERNAME }}
|
||||
password: ${{ secrets.GHCR_PERSONAL_TOKEN }}
|
||||
username: ${{ github.actor }}
|
||||
password: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
- name: Build and push docker to Github Container Registry
|
||||
uses: docker/build-push-action@v2
|
||||
uses: docker/build-push-action@v5
|
||||
with:
|
||||
push: true
|
||||
platforms: linux/amd64,linux/arm64,linux/386
|
||||
tags: |
|
||||
ghcr.io/${{ secrets.REGISTRY_USERNAME }}/prometheus-qbittorrent-exporter:latest
|
||||
ghcr.io/${{ secrets.REGISTRY_USERNAME }}/prometheus-qbittorrent-exporter:${{ steps.extract_branch.outputs.tag }}
|
||||
tags: ${{ steps.metaghcr.outputs.tags }}
|
||||
labels: ${{ steps.metaghcr.outputs.labels }}
|
||||
|
||||
2
.github/workflows/pythonpublish.yml
vendored
2
.github/workflows/pythonpublish.yml
vendored
@@ -12,7 +12,7 @@ jobs:
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v1
|
||||
with:
|
||||
python-version: '3.6'
|
||||
python-version: '3.11'
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
A prometheus exporter for qBitorrent. Get metrics from a server and offers them in a prometheus format.
|
||||
|
||||
     [](https://htmlpreview.github.io/?https://github.com/esanchezm/prometheus-qbittorrent-exporter/blob/python-coverage-comment-action-data/htmlcov/index.html)
|
||||
      [](https://htmlpreview.github.io/?https://github.com/esanchezm/prometheus-qbittorrent-exporter/blob/python-coverage-comment-action-data/htmlcov/index.html)
|
||||
|
||||
## How to use it
|
||||
|
||||
|
||||
Reference in New Issue
Block a user