mirror of
https://github.com/invoiceninja/dockerfiles.git
synced 2025-12-31 19:47:25 +01:00
5
.github/workflows/publish-image-debian.yaml
vendored
5
.github/workflows/publish-image-debian.yaml
vendored
@@ -15,6 +15,7 @@ jobs:
|
||||
version: ${{ steps.version.outputs.version }}
|
||||
major: ${{ steps.version.outputs.major }}
|
||||
minor: ${{ steps.version.outputs.minor }}
|
||||
url: ${{ steps.version.outputs.url }}
|
||||
steps:
|
||||
- id: version
|
||||
run: |
|
||||
@@ -25,6 +26,7 @@ jobs:
|
||||
fi
|
||||
MAJOR="$(echo "${VERSION}" | cut -d. -f1)"
|
||||
MINOR="$(echo "${VERSION}" | cut -d. -f2)"
|
||||
URL=https://github.com/invoiceninja/invoiceninja/releases/download/v${VERSION}/invoiceninja.tar.gz
|
||||
|
||||
# Debug output
|
||||
echo "Current version: ${VERSION}"
|
||||
@@ -33,6 +35,7 @@ jobs:
|
||||
echo "version=${VERSION}" >> $GITHUB_OUTPUT
|
||||
echo "major=${MAJOR}" >> $GITHUB_OUTPUT
|
||||
echo "minor=${MINOR}" >> $GITHUB_OUTPUT
|
||||
echo "url=${URL}" >> $GITHUB_OUTPUT
|
||||
|
||||
build:
|
||||
runs-on: ${{ startsWith(matrix.platform, 'linux/arm') && 'ubuntu-24.04-arm' || 'ubuntu-latest' }}
|
||||
@@ -75,7 +78,7 @@ jobs:
|
||||
uses: docker/build-push-action@v6
|
||||
with:
|
||||
context: debian
|
||||
build-args: INVOICENINJA_VERSION=${{ needs.version.outputs.version }}
|
||||
build-args: URL=${{ needs.version.outputs.url }}
|
||||
platforms: ${{ matrix.platform }}
|
||||
labels: ${{ steps.meta.outputs.labels }}
|
||||
tags: ${{ env.REGISTRY_IMAGE }}
|
||||
|
||||
8
debian/Dockerfile
vendored
8
debian/Dockerfile
vendored
@@ -2,9 +2,9 @@ ARG PHP=8.4
|
||||
|
||||
FROM php:${PHP}-fpm AS prepare-app
|
||||
|
||||
ADD https://github.com/invoiceninja/invoiceninja/releases/latest/download/invoiceninja.tar.gz /tmp/invoiceninja.tar.gz
|
||||
ARG URL=https://github.com/invoiceninja/invoiceninja/releases/latest/download/invoiceninja.tar.gz
|
||||
|
||||
USER www-data
|
||||
ADD ${URL} /tmp/invoiceninja.tar.gz
|
||||
|
||||
RUN tar -xzf /tmp/invoiceninja.tar.gz -C /var/www/html \
|
||||
&& ln -s /var/www/html/resources/views/react/index.blade.php /var/www/html/public/index.html \
|
||||
@@ -76,8 +76,8 @@ RUN echo "skip-ssl = true" >> /etc/mysql/mariadb.conf.d/50-client.cnf
|
||||
COPY supervisor/supervisord.conf /etc/supervisor/conf.d/supervisord.conf
|
||||
|
||||
# Setup InvoiceNinja
|
||||
COPY --from=prepare-app /var/www/html /var/www/html
|
||||
COPY --from=prepare-app /tmp/public /tmp/public
|
||||
COPY --from=prepare-app --chown=www-data:www-data /var/www/html /var/www/html
|
||||
COPY --from=prepare-app --chown=www-data:www-data /tmp/public /tmp/public
|
||||
|
||||
# Add initialization script
|
||||
COPY --chmod=0755 scripts/init.sh /usr/local/bin/init.sh
|
||||
|
||||
Reference in New Issue
Block a user