mirror of
https://github.com/invoiceninja/dockerfiles.git
synced 2026-01-21 13:54:03 +01:00
Merge pull request #639 from turbo124/debian
Enforce latest tags during build
This commit is contained in:
10
.github/workflows/publish-image.yaml
vendored
10
.github/workflows/publish-image.yaml
vendored
@@ -32,9 +32,13 @@ jobs:
|
|||||||
MAJOR="$(echo "${VERSION}" | cut -d. -f1)"
|
MAJOR="$(echo "${VERSION}" | cut -d. -f1)"
|
||||||
MINOR="$(echo "${VERSION}" | cut -d. -f2)"
|
MINOR="$(echo "${VERSION}" | cut -d. -f2)"
|
||||||
TAGS="$TAGS,${DOCKER_IMAGE}:${MAJOR},${DOCKER_IMAGE}:${MAJOR}.${MINOR}"
|
TAGS="$TAGS,${DOCKER_IMAGE}:${MAJOR},${DOCKER_IMAGE}:${MAJOR}.${MINOR}"
|
||||||
if [[ $VERSION =~ ^5\.[0-9]{1,3}\.[0-9]{1,3}$ ]]; then
|
|
||||||
TAGS="$TAGS,${DOCKER_IMAGE}:latest"
|
# Debug output
|
||||||
fi
|
echo "Current version: ${VERSION}"
|
||||||
|
echo "Version pattern check: $([[ $VERSION =~ ^5\.[0-9]{1,3}\.[0-9]{1,3}$ ]] && echo "matches" || echo "doesn't match")"
|
||||||
|
|
||||||
|
TAGS="$TAGS,${DOCKER_IMAGE}:latest"
|
||||||
|
|
||||||
echo "tags=${TAGS}" >> $GITHUB_OUTPUT # Updated output syntax
|
echo "tags=${TAGS}" >> $GITHUB_OUTPUT # Updated output syntax
|
||||||
echo "version=${VERSION}" >> $GITHUB_OUTPUT
|
echo "version=${VERSION}" >> $GITHUB_OUTPUT
|
||||||
echo "major=${MAJOR}" >> $GITHUB_OUTPUT
|
echo "major=${MAJOR}" >> $GITHUB_OUTPUT
|
||||||
|
|||||||
2
debian/Dockerfile
vendored
2
debian/Dockerfile
vendored
@@ -117,7 +117,7 @@ WORKDIR /var/www/html
|
|||||||
RUN set -eux; \
|
RUN set -eux; \
|
||||||
DOWNLOAD_URL=$(curl -s "https://api.github.com/repos/invoiceninja/invoiceninja/releases/latest" | \
|
DOWNLOAD_URL=$(curl -s "https://api.github.com/repos/invoiceninja/invoiceninja/releases/latest" | \
|
||||||
grep -o '"browser_download_url": "[^"]*invoiceninja.tar"' | cut -d '"' -f 4) && \
|
grep -o '"browser_download_url": "[^"]*invoiceninja.tar"' | cut -d '"' -f 4) && \
|
||||||
curl -L "$DOWNLOAD_URL" | tar -xvz -C /var/www/html && \
|
curl -L "$DOWNLOAD_URL" | tar -xfvz -C /var/www/html --overwrite && \
|
||||||
rm -rf /var/www/html/ui && \
|
rm -rf /var/www/html/ui && \
|
||||||
chown -R www-data:www-data /var/www/html
|
chown -R www-data:www-data /var/www/html
|
||||||
|
|
||||||
|
|||||||
4
debian/docker-compose.yml
vendored
4
debian/docker-compose.yml
vendored
@@ -8,7 +8,7 @@ x-logging: &default-logging
|
|||||||
|
|
||||||
services:
|
services:
|
||||||
app:
|
app:
|
||||||
image: invoiceninja/invoiceninja-debian:5
|
image: invoiceninja/invoiceninja-debian:5.10.55-d
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
env_file:
|
env_file:
|
||||||
- ./.env
|
- ./.env
|
||||||
@@ -35,7 +35,7 @@ services:
|
|||||||
image: nginx:alpine
|
image: nginx:alpine
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
ports:
|
ports:
|
||||||
- "80:80"
|
- "8013:80"
|
||||||
volumes:
|
volumes:
|
||||||
- ./nginx/conf.d:/etc/nginx/conf.d:ro
|
- ./nginx/conf.d:/etc/nginx/conf.d:ro
|
||||||
- ./nginx/nginx.conf:/etc/nginx/nginx.conf:ro
|
- ./nginx/nginx.conf:/etc/nginx/nginx.conf:ro
|
||||||
|
|||||||
Reference in New Issue
Block a user