Commit graph

39 commits

Author SHA1 Message Date
copilot-swe-agent[bot]
6a1792d46a Simplify asset build: copy entire project instead of individual files
Refactored to copy the entire project directory in composer-deps and assets stages instead of cherry-picking specific files. This:
- Eliminates the separate translations stage
- Avoids missing file issues
- Simplifies the build process
- Maintains performance benefit of building assets once on native platform

Both stages now use COPY . . to get all project files, avoiding the complexity of tracking which files are needed.

Co-authored-by: jbtronics <5410681+jbtronics@users.noreply.github.com>
2025-12-07 20:48:51 +00:00
copilot-swe-agent[bot]
9402382d56 Copy .env file to translations stage for Symfony console commands
Symfony console requires .env file to bootstrap. Added COPY .env to translations stage so cache:warmup can run successfully.

Co-authored-by: jbtronics <5410681+jbtronics@users.noreply.github.com>
2025-12-07 21:43:35 +01:00
copilot-swe-agent[bot]
a604ec8476 Add translations stage to generate Symfony translations for webpack
Webpack build requires var/translations files generated by Symfony's cache warmup. Added intermediate 'translations' stage that:
- Copies composer dependencies and app files
- Generates autoloader
- Runs cache warmup to create translation files
- Assets stage now copies these translations before building

This fixes the webpack build errors about missing translation exports.

Co-authored-by: jbtronics <5410681+jbtronics@users.noreply.github.com>
2025-12-07 21:43:35 +01:00
copilot-swe-agent[bot]
564b8f2891 Add git package to Dockerfile base stage
Git is required by composer when installing packages from source. This dependency was exposed by the multi-stage build changes where composer-deps stage uses --no-scripts and the final stage needs to complete the installation.

Co-authored-by: jbtronics <5410681+jbtronics@users.noreply.github.com>
2025-12-07 21:43:35 +01:00
copilot-swe-agent[bot]
84fa326839 Remove redundant --chown flag from COPY in Dockerfile
The assets are copied while running as www-data user, so the --chown flag is redundant. This makes it consistent with the frankenphp version.

Co-authored-by: jbtronics <5410681+jbtronics@users.noreply.github.com>
2025-12-07 21:43:35 +01:00
copilot-swe-agent[bot]
2e79df3155 Optimize Docker build: Build assets outside ARM emulation
- Add multi-stage build with separate composer-deps and assets stages
- Assets are built once on native platform (node:22-bookworm-slim)
- Pre-built assets copied into final images for all platforms
- Remove Node.js/Yarn installation from final images (smaller size)
- Use --ignore-platform-reqs for composer in assets stage
- Applies to both Dockerfile and Dockerfile-frankenphp

Co-authored-by: jbtronics <5410681+jbtronics@users.noreply.github.com>
2025-12-07 21:43:35 +01:00
Jan Böhmer
9a8e34cbe3 Changed classical docker image in the way that we do not need to passthrough env vars explicitly 2025-08-30 21:40:24 +02:00
Jan Böhmer
93b04fbf94 Use nodejs 22 in docker images
Some checks failed
Build assets artifact / Build assets artifact (push) Has been cancelled
Docker Image Build / docker (push) Has been cancelled
Docker Image Build (FrankenPHP) / docker (push) Has been cancelled
Static analysis / Static analysis (push) Has been cancelled
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.2, mysql) (push) Has been cancelled
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.3, mysql) (push) Has been cancelled
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.4, mysql) (push) Has been cancelled
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.2, postgres) (push) Has been cancelled
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.3, postgres) (push) Has been cancelled
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.4, postgres) (push) Has been cancelled
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.2, sqlite) (push) Has been cancelled
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.3, sqlite) (push) Has been cancelled
PHPUnit Tests / PHPUnit and coverage Test (PHP 8.4, sqlite) (push) Has been cancelled
2025-08-30 00:32:43 +02:00
Jan Böhmer
a2d94b54b1 Use PHP 8.4 in docker images 2025-08-30 00:31:50 +02:00
Jan Böhmer
80129c0a88 Use PHP 8.3 as docker image, and allow for longer error log lines
This fixes issue #781
2024-12-01 22:34:05 +01:00
Jan Böhmer
8c8b44baef Use debian bookworm, PHP 8.2 and node 20 for the docker image by default 2024-09-08 19:40:43 +02:00
Jan Böhmer
7366a33fe5 Apply the PHP_VERSION arg also to the partdb-entrypoint during build, to make it really version independent 2024-09-08 19:40:19 +02:00
David Girón
b5a0189f29
feat(docker): Refactor Dockerfile (#683)
* reorder nodejs/yarn install, separate packages per line

* reduce run actions and reorganize commands

* simplify file creation, copy in one layer only

* fix lint LegacyKeyValueFormat

* arg php_version to run different version

* reorder copy from generated config

* update dockerfile-frankenphp
2024-09-08 19:13:13 +02:00
Jan Böhmer
228549ff51 Include pgsql extensions and client in docker images 2024-07-28 13:12:42 +02:00
au-ee
7c258d231b
install sudo to be able to do db migrations from the container's console (#566) 2024-03-12 11:03:33 +01:00
Jan Böhmer
a3b5243ffc Install mysqldump in docker, so the builtin backup solution can be used
Fixes issue #479
2024-01-14 21:31:37 +01:00
Jan Böhmer
377e2eb613 Properly redirect the stdout of php-fpm to the docker logs
This fixes issue #298
2023-06-11 00:09:00 +02:00
Jan Böhmer
e808964913 Default docker container uses php-fpm and preloading now
This gives us a approx. 12% performance boost
2023-03-04 20:25:48 +01:00
Jan Böhmer
d3023ea945 Increase network timeout for yarn in Dockerfile to prevent timeout errors on cross builds. 2023-02-05 19:31:21 +01:00
Jan Böhmer
66e566b99a Use precompiled PHP extensions for docker container
This should hopefully reduce the build times for cross compiled images, as we dont have to build extensions from source there.
2023-02-05 18:58:57 +01:00
Jan Böhmer
156f611611 Do not build extenstions that are already existing in the docker image 2023-02-05 02:16:30 +01:00
Jan Böhmer
9273d6b249 Improved efficiency of Dockerfile 2023-02-05 00:46:30 +01:00
Jan Böhmer
49d7a527f5 Renamed demo environment to docker 2023-02-04 23:40:24 +01:00
Jan Böhmer
6f28029fb8 Added a custom docker entrypoint which chowns used volumes
This fixes issue #206.
2023-02-04 22:44:33 +01:00
Jan Böhmer
e8e1da9c61 Remove not needed node_modules/ folder during docker build
This should make the docker image a bit smaller (approx. 70 MB)
2022-08-13 01:40:00 +02:00
Jan Böhmer
fdcfb95ac7 Remove FOS CKEditor bundle as we dont use it anymore
We now use our self-written elements with CKEDITOR5
2022-07-26 21:26:30 +02:00
Jan Böhmer
a4f07e9b82 Dont use sudo in Dockerfile 2022-07-25 22:44:41 +02:00
Jan Böhmer
2da20535b0 Use newer nodejs version in docker builds
Our dependencies needs newer nodejs
2022-07-25 22:23:09 +02:00
Jan Böhmer
05ecbf3dfd Fixed syntax error in Dockerfile 2022-07-21 23:53:40 +02:00
Jan Böhmer
95fcc15634 Use PHP opcache with optimized configuration in docker image. 2022-07-21 23:34:38 +02:00
Jan Böhmer
8d85d2e737 Do not override customized GD with default one in Dockerfile 2022-07-21 23:12:47 +02:00
Jan Böhmer
d3d92d6013 Configure dockers GD with support with multiple file formats.
Should fix issue #122 and #115
2022-07-21 22:53:59 +02:00
Jan Böhmer
49b0ef02d4 Use PHP8.1 as docker base image. 2022-07-21 00:59:34 +02:00
Jan Böhmer
c5c5ce77e9 Updated Dockerfile to support JPEG files in docker. Fixes issue #115. 2021-06-09 09:01:21 +02:00
Jan Böhmer
fb115fe920 Improved Dockerfile 2021-03-14 22:12:55 +01:00
Jan Böhmer
916f38b5c3 Dont install prestissimo in docker image, as it is not supported anymore with composer 2. 2021-03-14 18:51:55 +01:00
Jan Böhmer
8af9c6e7cd Fixed dockerfile 2019-12-01 15:44:32 +01:00
Jan Böhmer
4f70d8b1da Use dev HTTP-Kernel so we can generate code coverage again.
An error with the test container will be coming to 4.4.1 (which is not released yet). When it is available we should revert the changes to composer.json.
2019-11-30 22:53:45 +01:00
Jan Böhmer
87d6399175 Add Dockerfile. 2019-11-17 19:07:07 +01:00