From 70fb347fc407c249bb20360c28fafa2dce41d94c Mon Sep 17 00:00:00 2001 From: jekkos Date: Wed, 13 May 2026 20:55:59 +0200 Subject: [PATCH] fix(docker): correct permissions and fix migration barcode_type error (#4546) * fix(ci): include hidden files in Docker build context actions/upload-artifact@v4 excludes hidden files (dotfiles) by default, causing .htaccess files to be missing from the Docker image. Add include-hidden-files: true to preserve .htaccess in the build artifact. * fix(docker): correct permissions and add barcode_type default - Set proper permissions (750) for writable/logs, writable/uploads, writable/cache, public/uploads, and public/uploads/item_pics - Set permissions (640) for writable/uploads/importCustomers.csv - Add barcode_type default value to prevent 'unknown key' error during initial migration when database is not yet initialized --------- Co-authored-by: Ollama Co-authored-by: objecttothis <17935339+objecttothis@users.noreply.github.com> --- Dockerfile | 3 ++- app/Config/OSPOS.php | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index db1f8a1c1..4180c9259 100644 --- a/Dockerfile +++ b/Dockerfile @@ -13,7 +13,8 @@ RUN echo "date.timezone = \"\${PHP_TIMEZONE}\"" > /usr/local/etc/php/conf.d/time WORKDIR /app COPY --chown=www-data:www-data . /app -RUN chmod 770 /app/writable/uploads /app/writable/logs /app/writable/cache \ +RUN chmod 750 /app/writable/logs /app/writable/uploads /app/writable/cache /app/public/uploads /app/public/uploads/item_pics \ + && chmod 640 /app/writable/uploads/importCustomers.csv \ && ln -s /app/*[^public] /var/www \ && rm -rf /var/www/html \ && ln -nsf /app/public /var/www/html diff --git a/app/Config/OSPOS.php b/app/Config/OSPOS.php index 1f411394d..ecc6eb59a 100644 --- a/app/Config/OSPOS.php +++ b/app/Config/OSPOS.php @@ -48,7 +48,8 @@ class OSPOS extends BaseConfig $this->settings = [ 'language' => 'english', 'language_code' => 'en', - 'company' => 'Home' + 'company' => 'Home', + 'barcode_type' => 'Code39' ]; } }