1 Commits

Author SHA1 Message Date
renovate a5b544bba9 chore(deps): update debian docker tag to buster-20240612
Docker Build and Push / lint (pull_request) Successful in 6s
Docker Build and Push / build (pull_request) Successful in 49s
Docker Build and Push / test (pull_request) Successful in 21s
Docker Build and Push / push (pull_request) Has been skipped
2026-06-09 18:22:49 +00:00
10 changed files with 177 additions and 181 deletions
-44
View File
@@ -1,44 +0,0 @@
name: Nightly Rebuild
on:
schedule:
- cron: '0 0 * * *'
jobs:
hadolint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
- uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
continue-on-error: true
with:
dockerfile: Dockerfile
build-push:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
with:
fetch-depth: 0
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
- uses: docker/login-action@650006c6eb7dba73a995cc03b0b2d7f5ca915bee # v4
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- id: get-latest-tag
run: |
TAG=$(git describe --tags --abbrev=0 2>/dev/null || echo "")
echo "tag=$TAG" >> $GITHUB_OUTPUT
- id: meta
uses: docker/metadata-action@80c7e94dd9b9319bd5eb7a0e0fe9291e23a2a2e9 # v6
with:
images: jcabillot/sabnzbd
tags: |
type=raw,value=${{ steps.get-latest-tag.outputs.tag }}-latest,enable=${{ steps.get-latest-tag.outputs.tag != '' }}
- uses: docker/build-push-action@53b7df96c91f9c12dcc8a07bcb9ccacbed38856a # v7.3.0
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
pull: true
+82
View File
@@ -0,0 +1,82 @@
name: Docker Build and Push
on:
pull_request:
branches: [master]
push:
branches: [master]
schedule:
- cron: '0 0 * * *'
jobs:
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6
- name: Hadolint
uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
with:
dockerfile: Dockerfile
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6
- name: Build image
run: docker build -t ci-image:${{ github.sha }} .
- name: Save image
run: docker save -o image.tar ci-image:${{ github.sha }}
- name: Upload artifact
uses: https://github.com/ChristopherHX/gitea-upload-artifact@62ac910c5d3dfa85c7cb2df15afe2e342b2407c2 # main
with:
name: docker-image
path: image.tar
retention-days: 1
test:
runs-on: ubuntu-latest
needs: [lint, build]
steps:
- name: Checkout
uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6
- name: Download artifact
uses: https://github.com/ChristopherHX/gitea-download-artifact@75635f32b4c1c41c4b3d64e8f85210112ed4c9c7 # main
with:
name: docker-image
- name: Load image
run: docker load < image.tar
- name: Run tests
run: bash tests/test.sh ci-image:${{ github.sha }}
push:
runs-on: ubuntu-latest
needs: test
if: github.event_name != 'pull_request'
steps:
- name: Download artifact
uses: https://github.com/ChristopherHX/gitea-download-artifact@75635f32b4c1c41c4b3d64e8f85210112ed4c9c7 # main
with:
name: docker-image
- name: Load image
run: docker load < image.tar
- name: Login to Docker Hub
uses: docker/login-action@650006c6eb7dba73a995cc03b0b2d7f5ca915bee # v4
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Tag and push
run: |
docker tag ci-image:${{ github.sha }} jcabillot/sabnzbd:latest
docker push jcabillot/sabnzbd:latest
-49
View File
@@ -1,49 +0,0 @@
name: Main Release
on:
push:
branches: [master]
jobs:
hadolint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
- uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
continue-on-error: true
with:
dockerfile: Dockerfile
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
- run: docker build --load -t ci-image:${{ github.sha }} .
- run: bash tests/test.sh ci-image:${{ github.sha }}
build:
needs: [test]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
- run: docker build -t jcabillot/sabnzbd:${{ github.sha }} .
tag:
needs: [build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
with:
fetch-depth: 0
- name: Configure git auth
run: |
git remote set-url origin "https://x-access-token:${{ secrets.SA_TOKEN_ACTION_PUSH_TAGS }}@scm.cabillot.eu/web/sabnzbd.git"
- uses: anothrNick/github-tag-action@4ed44965e0db8dab2b466a16da04aec3cc312fd8 # v1.75.0
env:
GITHUB_TOKEN: ${{ secrets.SA_TOKEN_ACTION_PUSH_TAGS }}
DEFAULT_BUMP: patch
RELEASE_BRANCHES: master
WITH_V: true
GIT_API_TAGGING: false
-23
View File
@@ -1,23 +0,0 @@
name: PR Checks
on:
pull_request:
branches: [master]
jobs:
hadolint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
- uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
continue-on-error: true
with:
dockerfile: Dockerfile
build-test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
- run: docker build -t ci-image:${{ github.sha }} .
- run: bash tests/test.sh ci-image:${{ github.sha }}
-48
View File
@@ -1,48 +0,0 @@
name: Tag Release
on:
push:
tags: ['*']
jobs:
hadolint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
- uses: hadolint/hadolint-action@2332a7b74a6de0dda2e2221d575162eba76ba5e5 # v3.3.0
continue-on-error: true
with:
dockerfile: Dockerfile
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
- run: docker build --load -t ci-image:${{ github.sha }} .
- run: bash tests/test.sh ci-image:${{ github.sha }}
build-push:
needs: [test]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7
- uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c # v4
- uses: docker/login-action@650006c6eb7dba73a995cc03b0b2d7f5ca915bee # v4
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- id: meta
uses: docker/metadata-action@80c7e94dd9b9319bd5eb7a0e0fe9291e23a2a2e9 # v6
with:
images: jcabillot/sabnzbd
tags: |
type=ref,event=tag
type=ref,event=tag,suffix=-latest
- uses: docker/build-push-action@53b7df96c91f9c12dcc8a07bcb9ccacbed38856a # v7.3.0
with:
context: .
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
pull: true
+23
View File
@@ -0,0 +1,23 @@
image: docker:latest
services:
- docker:dind
before_script:
- docker login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" $CI_REGISTRY
build-master:
stage: build
script:
- docker build --pull -t "$CI_REGISTRY_IMAGE" .
- docker push "$CI_REGISTRY_IMAGE"
only:
- master
build:
stage: build
script:
- docker build --pull -t "$CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG" .
- docker push "$CI_REGISTRY_IMAGE:$CI_COMMIT_REF_SLUG"
except:
- master
+8 -8
View File
@@ -1,4 +1,4 @@
FROM debian:trixie-20260623 FROM debian:buster-20240612
LABEL maintainer="Julien Cabillot <dockerimages@cabillot.eu>" LABEL maintainer="Julien Cabillot <dockerimages@cabillot.eu>"
RUN groupadd -r -g 666 sabnzbd && \ RUN groupadd -r -g 666 sabnzbd && \
@@ -22,20 +22,20 @@ ENV LANG C.UTF-8
# #
# hadolint ignore=DL3008,DL3015,SC3009,DL3003,DL3013,DL3042 # hadolint ignore=DL3008,DL3015,SC3009,DL3003,DL3013,DL3042
RUN export SABNZBD_VERSION=4.5.5 PAR2CMDLINE_VERSION=v0.6.14-mt1 && \ RUN export SABNZBD_VERSION=3.7.2 PAR2CMDLINE_VERSION=v0.6.14-mt1 && \
export DEBIAN_FRONTEND=noninteractive && \ export DEBIAN_FRONTEND=noninteractive && \
export PIP_BREAK_SYSTEM_PACKAGES=1 && \
export BUILD_PACKAGES="automake build-essential python3-dev libffi-dev" && \ export BUILD_PACKAGES="automake build-essential python3-dev libffi-dev" && \
export RUNTIME_PACKAGES="ca-certificates p7zip-full unrar unzip libgomp1 openssl python3-openssl python3-cffi curl python3-pip" && \ export RUNTIME_PACKAGES="ca-certificates p7zip-full python3-yenc unrar unzip libgomp1 openssl python3-openssl curl python3-pip" && \
sed -i "s/Components: main/Components: main contrib non-free/" /etc/apt/sources.list.d/debian.sources && \ export PIP_PACKAGES="sabyenc" && \
sed -i 's|http://deb.debian.org|http://archive.debian.org|g' /etc/apt/sources.list && \
sed -i "s/ main$/ main contrib non-free/" /etc/apt/sources.list && \
apt-get -qq update && \ apt-get -qq update && \
apt-get -qq --yes install $BUILD_PACKAGES $RUNTIME_PACKAGES && \ apt-get -qq --yes install $BUILD_PACKAGES $RUNTIME_PACKAGES && \
#pip3 install $PIP_PACKAGES && \
curl -SL -o /tmp/sabnzbd.tar.gz https://github.com/sabnzbd/sabnzbd/releases/download/${SABNZBD_VERSION}/SABnzbd-${SABNZBD_VERSION}-src.tar.gz && \ curl -SL -o /tmp/sabnzbd.tar.gz https://github.com/sabnzbd/sabnzbd/releases/download/${SABNZBD_VERSION}/SABnzbd-${SABNZBD_VERSION}-src.tar.gz && \
tar xzf /tmp/sabnzbd.tar.gz && \ tar xzf /tmp/sabnzbd.tar.gz && \
mv SABnzbd-* sabnzbd && \ mv SABnzbd-* sabnzbd && \
sed -i '/pywin32/d' /sabnzbd/requirements.txt && \ pip3 install --upgrade pip && \
sed -i 's/^cffi==.*/cffi/' /sabnzbd/requirements.txt && \
sed -i 's/^cryptography==.*/cryptography/' /sabnzbd/requirements.txt && \
pip3 install -r /sabnzbd/requirements.txt && \ pip3 install -r /sabnzbd/requirements.txt && \
chown -R sabnzbd: sabnzbd && \ chown -R sabnzbd: sabnzbd && \
curl -o /tmp/par2cmdline-mt.tar.gz https://codeload.github.com/jkansanen/par2cmdline-mt/tar.gz/${PAR2CMDLINE_VERSION} && \ curl -o /tmp/par2cmdline-mt.tar.gz https://codeload.github.com/jkansanen/par2cmdline-mt/tar.gz/${PAR2CMDLINE_VERSION} && \
Vendored
+39
View File
@@ -0,0 +1,39 @@
pipeline {
environment {
registry = 'https://registry.hub.docker.com'
registryCredential = 'dockerhub_jcabillot'
dockerImage = 'jcabillot/sabnzbd'
DOCKER_BUILDKIT = '1'
}
agent any
triggers {
cron('@midnight')
}
stages {
stage('Clone repository') {
steps{
checkout scm
}
}
stage('Build image') {
steps{
sh 'docker build --force-rm=true --no-cache=true --pull -t ${dockerImage} .'
}
}
stage('Deploy Image') {
steps{
script {
withCredentials([usernamePassword(credentialsId: 'dockerhub_jcabillot', usernameVariable: 'DOCKER_USER', passwordVariable: 'DOCKER_PASS')]) {
sh 'docker login --username ${DOCKER_USER} --password ${DOCKER_PASS}'
sh 'docker push ${dockerImage}'
}
}
}
}
}
}
+22 -6
View File
@@ -1,23 +1,39 @@
{ {
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
"customManagers": [ "customManagers": [
{ {
"customType": "regex", "customType": "regex",
"managerFilePatterns": ["/^Dockerfile$/"], "description": "Detect SABnzbd release version pin",
"matchStrings": ["SABNZBD_VERSION=(?<currentValue>[0-9\\.]+)"], "managerFilePatterns": [
"/^Dockerfile$/"
],
"matchStrings": [
"SABNZBD_VERSION=(?<currentValue>[0-9.]+)"
],
"depNameTemplate": "sabnzbd/sabnzbd", "depNameTemplate": "sabnzbd/sabnzbd",
"datasourceTemplate": "github-releases" "datasourceTemplate": "github-releases"
}, },
{ {
"customType": "regex", "customType": "regex",
"managerFilePatterns": ["/^Dockerfile$/"], "description": "Detect Tini release version pin",
"matchStrings": ["\"TINI_VERSION\"\\s+\"v?(?<currentValue>[0-9\\.]+)\""], "managerFilePatterns": [
"/^Dockerfile$/"
],
"matchStrings": [
"TINI_VERSION\\s+v?(?<currentValue>[0-9.]+)"
],
"depNameTemplate": "krallin/tini", "depNameTemplate": "krallin/tini",
"datasourceTemplate": "github-releases" "datasourceTemplate": "github-releases"
}, },
{ {
"customType": "regex", "customType": "regex",
"managerFilePatterns": ["/^Dockerfile$/"], "description": "Detect par2cmdline release version pin",
"matchStrings": ["PAR2CMDLINE_VERSION=v?(?<currentValue>[\\w\\.-]+)"], "managerFilePatterns": [
"/^Dockerfile$/"
],
"matchStrings": [
"PAR2CMDLINE_VERSION=v?(?<currentValue>[0-9a-z.]+-mt\\d+)"
],
"depNameTemplate": "jkansanen/par2cmdline-mt", "depNameTemplate": "jkansanen/par2cmdline-mt",
"datasourceTemplate": "github-tags" "datasourceTemplate": "github-tags"
} }
+1 -1
View File
@@ -70,7 +70,7 @@ done
echo "" echo ""
echo "Test: GET / (SABnzbd web UI)" echo "Test: GET / (SABnzbd web UI)"
RESPONSE=$(curl -sL -D - "$BASE_URL/") RESPONSE=$(curl -s -D - "$BASE_URL/")
STATUS=$(echo "$RESPONSE" | head -1 | grep -oP '\d{3}') STATUS=$(echo "$RESPONSE" | head -1 | grep -oP '\d{3}')
BODY=$(echo "$RESPONSE" | sed -n '/^\r$/,$p' | tail -n +2) BODY=$(echo "$RESPONSE" | sed -n '/^\r$/,$p' | tail -n +2)