Skip to content

Commit 676b12e

Browse files
committed
Finish merging php.ini files
1 parent d2fba6e commit 676b12e

File tree

6 files changed

+9
-58
lines changed

6 files changed

+9
-58
lines changed

layers/fpm/bref.ini

Lines changed: 0 additions & 51 deletions
This file was deleted.

php-84/Dockerfile

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -535,12 +535,12 @@ FROM public.ecr.aws/lambda/provided:al2-${IMAGE_VERSION_SUFFIX} as function
535535
# We selected the files in /bref-layer, now we copy them to /opt (the real directory for the Lambda layer)
536536
COPY --link --from=build-environment /bref-layer /opt
537537

538-
COPY --link layers/php.ini /opt/bref/etc/php/conf.d/bref.ini
539-
COPY --link layers/php-fpm.conf /opt/bref/etc/php-fpm.conf
538+
COPY --link src/php.ini /opt/bref/etc/php/conf.d/bref.ini
539+
COPY --link src/php-fpm.conf /opt/bref/etc/php-fpm.conf
540540

541-
COPY --link layers/bootstrap.php /opt/bootstrap
541+
COPY --link src/bootstrap.php /opt/bootstrap
542542
# Copy files to /var/runtime to support deploying as a Docker image
543-
COPY --link layers/bootstrap.php /var/runtime/bootstrap
543+
COPY --link src/bootstrap.php /var/runtime/bootstrap
544544
RUN chmod +x /opt/bootstrap && chmod +x /var/runtime/bootstrap
545545

546546

@@ -558,7 +558,7 @@ RUN cp $(php -r "echo ini_get('extension_dir');")/xdebug.so /opt/bref/extensions
558558
FROM function as dev
559559

560560
COPY --link --from=build_dev /opt /opt
561-
COPY --link layers/dev-entrypoint.sh /bref-entrypoint.sh
561+
COPY --link src/dev-entrypoint.sh /bref-entrypoint.sh
562562
RUN chmod +x /bref-entrypoint.sh
563563

564564
# Install node to run the JS app below
File renamed without changes.
File renamed without changes.

layers/php.ini renamed to src/php.ini

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,10 @@ memory_limit=10240M
1212
opcache.enable=1
1313
opcache.enable_cli=1
1414

15-
; Store the opcodes into a file cache instead of memory
16-
; Since PHP runs on lambdas with a new process each time the memory cache is lost
15+
; Store the opcodes into a file cache (on top of storing in memory)
16+
; With FPM, this is only useful if FPM restarts or if the shared memory cache is full.
17+
; With the function runtime, this is useful when the function restarts the PHP
18+
; process on every invocation.
1719
; TODO store in a subdirectory (but the problem is that the subdirectory doesn't exist when PHP starts...)
1820
opcache.file_cache="/tmp"
1921
; Disable the memory cache since it's useless

0 commit comments

Comments
 (0)