7 Commits

Author SHA1 Message Date
sebastas b8e7570dc0 fix: update user and group modification logic in entrypoint script (again)
Build and publish Docker image / build-and-push (release) Successful in 19s
2026-07-02 16:36:23 +02:00
sebastas 624dc336a0 fix: update package version to 1.0.1 and resolve dependencies
Build and publish Docker image / build-and-push (release) Successful in 1m9s
2026-07-02 16:25:40 +02:00
sebastas 8eb97b4598 fix: add missing dependencies for build process in Dockerfile
Build and publish Docker image / build-and-push (release) Failing after 15s
2026-07-02 16:16:04 +02:00
sebastas 186b5840a4 fix: enhance user and group ID remapping logic in entrypoint script
Build and publish Docker image / build-and-push (release) Failing after 13s
2026-07-02 16:06:46 +02:00
sebastas 260c8475a4 fix: remove public COPY (directory not used)
Build and publish Docker image / build-and-push (release) Successful in 17s
2026-06-06 17:45:23 +02:00
sebastas dbbca3c13e Version 1.0.0
Build and publish Docker image / build-and-push (release) Failing after 3m35s
2026-06-06 17:39:20 +02:00
sebastas 1094b2c92b Added workflow for publishing package 2026-06-06 17:38:20 +02:00
5 changed files with 97 additions and 7 deletions
+48
View File
@@ -0,0 +1,48 @@
name: Build and publish Docker image
on:
release:
types: [published]
env:
REGISTRY: gitea.kanawave.net
REGISTRY_USERNAME: sebastas
IMAGE_NAME: ${{ gitea.repository }}
jobs:
build-and-push:
runs-on: ubuntu-latest
# Permissions are not yet supported in Gitea Actions -> https://github.com/go-gitea/gitea/issues/23642#issuecomment-2119876692
# permissions:
# contents: read
# packages: write
# attestations: write
# id-token: write
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Login to registry
uses: docker/login-action@v2
with:
registry: ${{ env.REGISTRY }}
username: ${{ env.REGISTRY_USERNAME }}
password: ${{ secrets.REGISTRY_TOKEN }}
- name: Extract metadata (tags, labels)
id: meta
uses: docker/metadata-action@v4
with:
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
- name: Build and push
id: push
uses: docker/build-push-action@v5
with:
context: .
# file: ./Dockerfile
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
+1 -1
View File
@@ -1,6 +1,7 @@
# ── Stage 1: deps ───────────────────────────────────────────────────────────── # ── Stage 1: deps ─────────────────────────────────────────────────────────────
FROM node:24-alpine3.21 AS deps FROM node:24-alpine3.21 AS deps
WORKDIR /app WORKDIR /app
RUN apk add --no-cache python3 make g++
COPY package.json package-lock.json ./ COPY package.json package-lock.json ./
RUN npm ci RUN npm ci
@@ -28,7 +29,6 @@ RUN apk add --no-cache su-exec shadow && \
# Copy standalone build output # Copy standalone build output
COPY --from=builder --chown=nextjs:nodejs /app/.next/standalone ./ COPY --from=builder --chown=nextjs:nodejs /app/.next/standalone ./
COPY --from=builder --chown=nextjs:nodejs /app/.next/static ./.next/static COPY --from=builder --chown=nextjs:nodejs /app/.next/static ./.next/static
COPY --from=builder --chown=nextjs:nodejs /app/public ./public
COPY --chmod=755 entrypoint.sh /entrypoint.sh COPY --chmod=755 entrypoint.sh /entrypoint.sh
EXPOSE 3000 EXPOSE 3000
+8
View File
@@ -6,9 +6,17 @@ PGID=${PGID:-1001}
# Only remap if the requested IDs differ from the defaults baked into the image # Only remap if the requested IDs differ from the defaults baked into the image
if [ "$PGID" != "1001" ]; then if [ "$PGID" != "1001" ]; then
existing_group=$(getent group "$PGID" | cut -d: -f1)
if [ -n "$existing_group" ] && [ "$existing_group" != "nodejs" ]; then
groupmod -g "$((PGID + 50000))" "$existing_group"
fi
groupmod -g "$PGID" nodejs groupmod -g "$PGID" nodejs
fi fi
if [ "$PUID" != "1001" ]; then if [ "$PUID" != "1001" ]; then
existing_user=$(getent passwd "$PUID" | cut -d: -f1)
if [ -n "$existing_user" ] && [ "$existing_user" != "nextjs" ]; then
usermod -u "$((PUID + 50000))" "$existing_user"
fi
usermod -u "$PUID" nextjs usermod -u "$PUID" nextjs
fi fi
+39 -5
View File
@@ -1,12 +1,12 @@
{ {
"name": "tally-counter", "name": "tally-counter",
"version": "0.1.0", "version": "1.0.1",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "tally-counter", "name": "tally-counter",
"version": "0.1.0", "version": "1.0.1",
"dependencies": { "dependencies": {
"@dnd-kit/core": "^6.3.1", "@dnd-kit/core": "^6.3.1",
"@dnd-kit/sortable": "^10.0.0", "@dnd-kit/sortable": "^10.0.0",
@@ -348,9 +348,9 @@
} }
}, },
"node_modules/@emnapi/wasi-threads": { "node_modules/@emnapi/wasi-threads": {
"version": "1.2.1", "version": "1.2.2",
"resolved": "https://registry.npmjs.org/@emnapi/wasi-threads/-/wasi-threads-1.2.1.tgz", "resolved": "https://registry.npmjs.org/@emnapi/wasi-threads/-/wasi-threads-1.2.2.tgz",
"integrity": "sha512-uTII7OYF+/Mes/MrcIOYp5yOtSMLBWSIoLPpcgwipoiKbli6k322tcoFsxoIIxPDqW01SQGAgko4EzZi2BNv2w==", "integrity": "sha512-c95qOXkHdydNKhscBTebqEC1CVAZpyqOfVfBzQ1qgzyl3gfeldUjIggDbIZgDKsHLgnsM+igH7TJ/eAasaVuMA==",
"dev": true, "dev": true,
"license": "MIT", "license": "MIT",
"optional": true, "optional": true,
@@ -2222,6 +2222,40 @@
"node": ">=14.0.0" "node": ">=14.0.0"
} }
}, },
"node_modules/@unrs/resolver-binding-wasm32-wasi/node_modules/@emnapi/core": {
"version": "1.10.0",
"resolved": "https://registry.npmjs.org/@emnapi/core/-/core-1.10.0.tgz",
"integrity": "sha512-yq6OkJ4p82CAfPl0u9mQebQHKPJkY7WrIuk205cTYnYe+k2Z8YBh11FrbRG/H6ihirqcacOgl2BIO8oyMQLeXw==",
"dev": true,
"license": "MIT",
"optional": true,
"dependencies": {
"@emnapi/wasi-threads": "1.2.1",
"tslib": "^2.4.0"
}
},
"node_modules/@unrs/resolver-binding-wasm32-wasi/node_modules/@emnapi/runtime": {
"version": "1.10.0",
"resolved": "https://registry.npmjs.org/@emnapi/runtime/-/runtime-1.10.0.tgz",
"integrity": "sha512-ewvYlk86xUoGI0zQRNq/mC+16R1QeDlKQy21Ki3oSYXNgLb45GV1P6A0M+/s6nyCuNDqe5VpaY84BzXGwVbwFA==",
"dev": true,
"license": "MIT",
"optional": true,
"dependencies": {
"tslib": "^2.4.0"
}
},
"node_modules/@unrs/resolver-binding-wasm32-wasi/node_modules/@emnapi/wasi-threads": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/@emnapi/wasi-threads/-/wasi-threads-1.2.1.tgz",
"integrity": "sha512-uTII7OYF+/Mes/MrcIOYp5yOtSMLBWSIoLPpcgwipoiKbli6k322tcoFsxoIIxPDqW01SQGAgko4EzZi2BNv2w==",
"dev": true,
"license": "MIT",
"optional": true,
"dependencies": {
"tslib": "^2.4.0"
}
},
"node_modules/@unrs/resolver-binding-win32-arm64-msvc": { "node_modules/@unrs/resolver-binding-win32-arm64-msvc": {
"version": "1.12.2", "version": "1.12.2",
"resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-arm64-msvc/-/resolver-binding-win32-arm64-msvc-1.12.2.tgz", "resolved": "https://registry.npmjs.org/@unrs/resolver-binding-win32-arm64-msvc/-/resolver-binding-win32-arm64-msvc-1.12.2.tgz",
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "tally-counter", "name": "tally-counter",
"version": "0.1.0", "version": "1.0.0",
"private": true, "private": true,
"scripts": { "scripts": {
"dev": "next dev", "dev": "next dev",