Skip to content

Commit 6a93a56

Browse files
authored
Merge pull request #122 from brefphp/al2023
Switch to Amazon Linux 2023 for Bref v3
2 parents 57c642d + 6168124 commit 6a93a56

File tree

10 files changed

+26628
-1359
lines changed

10 files changed

+26628
-1359
lines changed

php-82/Dockerfile

Lines changed: 21 additions & 337 deletions
Large diffs are not rendered by default.

php-83/Dockerfile

Lines changed: 21 additions & 337 deletions
Large diffs are not rendered by default.

php-84/Dockerfile

Lines changed: 22 additions & 340 deletions
Large diffs are not rendered by default.

tests/test_2_extensions.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -86,9 +86,9 @@
8686
// https://github.com/brefphp/aws-lambda-layers/issues/53
8787
'curl-openssl-certificates' => file_exists(openssl_get_cert_locations()['default_cert_file']),
8888
// Check its location has not changed (would be a breaking change)
89-
'curl-openssl-certificates-location' => openssl_get_cert_locations()['default_cert_file'] === '/opt/bref/ssl/cert.pem',
90-
// Make sure we are using curl with our compiled libssh
91-
'curl-libssh' => version_compare(str_replace('libssh2/', '', curl_version()['libssh_version']), '1.10.0', '>='),
89+
'curl-openssl-certificates-location' => openssl_get_cert_locations()['default_cert_file'] === '/etc/pki/tls/cert.pem',
90+
// Check the file in previous Bref versions is still here (would be a breaking change)
91+
'curl-openssl-certificates-backwards-compatibility' => file_exists('/opt/bref/ssl/cert.pem'),
9292
'openssl' => (function() {
9393
$private_key = openssl_pkey_new(['private_key_bits' => 2048]);
9494
if ($private_key === false) {
@@ -121,6 +121,8 @@
121121
'sockets' => function_exists('socket_connect'),
122122
'spl' => class_exists(\SplQueue::class),
123123
'sqlite3' => class_exists(\SQLite3::class),
124+
// Drupal 11 requires SQLite >= 3.45.0
125+
'sqlite_version' => version_compare('3.45.0', \SQLite3::version()['versionString'], '<='),
124126
'tokenizer' => function_exists('token_get_all'),
125127
'libxml' => function_exists('libxml_get_errors'),
126128
'xml' => function_exists('xml_parse'),

utils/available-packages/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
update:
2+
docker compose run --rm update

utils/available-packages/al2023-packages.txt

Lines changed: 26332 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
services:
2+
3+
# List all packages that AL2023 provides with their version
4+
update:
5+
image: public.ecr.aws/lambda/provided:al2023-arm64
6+
entrypoint: /bin/sh
7+
command: [ "-c", "microdnf repoquery | sort > /tmp/al2023-packages.txt" ]
8+
volumes:
9+
- .:/tmp

utils/lib-copy/docker-compose.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@ services:
44

55
# List all files from `/lib64` into `libs-x86.txt`
66
update-x86:
7-
image: public.ecr.aws/lambda/provided:al2-x86_64
7+
image: public.ecr.aws/lambda/provided:al2023-x86_64
88
entrypoint: /bin/sh
9-
command: [ "-c", "find /lib64/ -maxdepth 1 -not -type d -printf '%f\n' | sort > /libs-x86.txt" ]
9+
command: [ "-c", "dnf install -y findutils && find /lib64/ -maxdepth 1 -not -type d -printf '%f\n' | sort > /libs-x86.txt" ]
1010
# Alternative approach from https://gist.github.com/vladgolubev/439559fc7597a4fb51eaa9e97b72f319
1111
# but it seems to list less files, so I'm not sure we should use that alternative
1212
# command: [ "-c", "/sbin/ldconfig -p | awk '{print $$1}' | sort > /al2-x64.txt" ]
@@ -15,8 +15,8 @@ services:
1515

1616
# List all files from `/lib64` into `libs-arm.txt`
1717
update-arm:
18-
image: public.ecr.aws/lambda/provided:al2-arm64
18+
image: public.ecr.aws/lambda/provided:al2023-arm64
1919
entrypoint: /bin/sh
20-
command: [ "-c", "find /lib64/ -maxdepth 1 -not -type d -printf '%f\n' | sort > /libs-arm.txt" ]
20+
command: [ "-c", "dnf install -y findutils && find /lib64/ -maxdepth 1 -not -type d -printf '%f\n' | sort > /libs-arm.txt" ]
2121
volumes:
2222
- ./libs-arm.txt:/libs-arm.txt

0 commit comments

Comments
 (0)