Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build-devel-image.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Publish Docker devel image
name: Build Docker devel image

on:
push:
Expand Down
20 changes: 5 additions & 15 deletions .github/workflows/build-image.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Publish Docker image
name: Build Docker image

on:
release:
Expand All @@ -15,41 +15,31 @@ jobs:
steps:
- name: Check out the repo
uses: actions/checkout@v6
# Production
with:
ref: 'main'
# Debug only
# with:
# ref: 'devel'

- name: Retrieve Repomanager version
run: |
echo "VERSION=$(cat ${GITHUB_WORKSPACE}/www/version)" >> $GITHUB_ENV
echo "Version: ${{ env.VERSION }}"

- 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: Log in to the container registry
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_TOKEN }}

# Build the images
# Build the image
- name: Build and push docker
uses: docker/build-push-action@v2
with:
file: Dockerfile
# Debug only
# push: true
# tags: lbr38/repomanager:devel
# platforms: linux/amd64,linux/arm64,linux/arm/v7

# Production
push: true
tags: lbr38/repomanager:latest, lbr38/repomanager:${{ env.VERSION }}
platforms: linux/amd64,linux/arm64,linux/arm/v7
7 changes: 2 additions & 5 deletions .github/workflows/phpcs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@ name: PHP CodeSniffer

on:
push:
branches: [ devel ]
pull_request:
push:
branches: [ main ]

jobs:
phpcs:
runs-on: ubuntu-latest
Expand All @@ -18,7 +15,7 @@ jobs:
- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.3'
php-version: '8.4'
coverage: none
tools: composer, cs2pr

Expand Down
3 changes: 0 additions & 3 deletions .github/workflows/phpstan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ name: PHPStan

on:
push:
branches: [ main, devel ]
pull_request:
branches: [ main ]

jobs:
phpstan:
Expand Down
3 changes: 0 additions & 3 deletions .github/workflows/source-repository-templates.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@ name: Validate source repository templates

on:
push:
branches: [ devel ]
pull_request:
branches: [ main, devel ]

jobs:
validate:
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/tasks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@ name: Run rpm and deb tasks

on:
push:
branches: [ devel ]
pull_request:
push:
branches: [ main ]

jobs:
run-deb-tasks:
Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/test-ansible-role.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@ name: Test ansible role

on:
push:
branches: [ devel ]
pull_request:
push:
branches: [ main ]

jobs:
ansible:
runs-on: ubuntu-latest
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/test-api.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ name: Test Repomanager API

on:
push:
branches: [ devel ]

jobs:
api-test:
Expand Down
5 changes: 1 addition & 4 deletions .github/workflows/test-database-update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,7 @@ name: Database update tests

on:
push:
branches: [ devel ]
pull_request:
push:
branches: [ main ]

jobs:
test-database-update:
runs-on: ubuntu-latest
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ WORKDIR ${DATA_DIR}

# Set healthcheck
# Check if nginx is responding on the expected port (default 8080 if NGINX_LISTEN_PORT is not set)
HEALTHCHECK --interval=30s --timeout=3s --retries=3 \
CMD /bin/sh -c 'curl -fsS http://localhost:${NGINX_LISTEN_PORT:-8080} || exit 1'
HEALTHCHECK --interval=30s --timeout=10s --retries=3 \
CMD /bin/sh -c 'curl -fsS http://127.0.0.1:${NGINX_LISTEN_PORT:-8080} || exit 1'

ENTRYPOINT ["/init"]
3 changes: 2 additions & 1 deletion www/controllers/Repo/Mirror/Deb.php
Original file line number Diff line number Diff line change
Expand Up @@ -721,7 +721,7 @@ private function downloadDebPackages($url) : void
*/

// First check if package has arch in its name, else ignore it
if (!preg_match('/(amd64|arm64|armel|armhf|i386|mips|mips64el|mipsel|ppc64el|s390x|all).deb$/', $debPackageName)) {
if (!preg_match('/(amd64|x64|arm64|armel|armhf|i386|mips|mips64el|mipsel|ppc64el|s390x|all).deb$/', $debPackageName)) {
$this->taskLogSubStepController->warning('Package does not have a valid arch in its name (ignoring)');
continue;
}
Expand All @@ -732,6 +732,7 @@ private function downloadDebPackages($url) : void
* e.g. filebeat-8.0.0.amd64.deb -> filebeat-8.0.0_amd64.deb
*/
$debPackageName = preg_replace('/[-.]amd64.deb$/', '_amd64.deb', $debPackageName);
$debPackageName = preg_replace('/[-.]x64.deb$/', '_amd64.deb', $debPackageName); // Some repositories use x64 instead of amd64 (e.g. opensearch)
$debPackageName = preg_replace('/[-.]arm64.deb$/', '_arm64.deb', $debPackageName);
$debPackageName = preg_replace('/[-.]armel.deb$/', '_armel.deb', $debPackageName);
$debPackageName = preg_replace('/[-.]armhf.deb$/', '_armhf.deb', $debPackageName);
Expand Down
2 changes: 1 addition & 1 deletion www/version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
5.13.3
5.13.4
Loading