Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
script: |
const matrix = {
cpu: ['x86', 'arm'],
php_version: ['80', '81', '82', '83', '84'],
php_version: ['82', '83', '84'],
}

// If this is a third-party pull request, skip ARM builds
Expand Down
16 changes: 8 additions & 8 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -35,29 +35,29 @@ default: docker-images layers


# Build Docker images *locally*
docker-images: docker-images-php-80 docker-images-php-81 docker-images-php-82 docker-images-php-83 docker-images-php-84
docker-images: docker-images-php-82 docker-images-php-83 docker-images-php-84
docker-images-php-%:
PHP_VERSION=$* ${BAKE_COMMAND} --load


# Build Lambda layers (zip files) *locally*
layers: layer-php-80 layer-php-81 layer-php-82 layer-php-83 layer-php-84
# This rule matches with a wildcard, for example `layer-php-80`.
# The `$*` variable will contained the matched part, in this case `php-80`.
layers: layer-php-82 layer-php-83 layer-php-84
# This rule matches with a wildcard, for example `layer-php-84`.
# The `$*` variable will contained the matched part, in this case `php-84`.
layer-%:
./utils/docker-zip-dir.sh bref/${CPU_PREFIX}$* ${CPU_PREFIX}$*


# Upload the layers to AWS Lambda
# Uses the current AWS_PROFILE. Most users will not want to use this option
# as this will publish all layers to all regions + publish all Docker images.
upload-layers: upload-layers-php-80 upload-layers-php-81 upload-layers-php-82 upload-layers-php-83 upload-layers-php-84
upload-layers: upload-layers-php-82 upload-layers-php-83 upload-layers-php-84
upload-layers-php-%:
LAYER_NAME=${CPU_PREFIX}php-$* $(MAKE) -C ./utils/lambda-publish publish-parallel


# Publish Docker images to Docker Hub.
upload-to-docker-hub: upload-to-docker-hub-php-80 upload-to-docker-hub-php-81 upload-to-docker-hub-php-82 upload-to-docker-hub-php-83 upload-to-docker-hub-php-84
upload-to-docker-hub: upload-to-docker-hub-php-82 upload-to-docker-hub-php-83 upload-to-docker-hub-php-84
upload-to-docker-hub-php-%:
# Make sure we have defined the docker tag
(test $(DOCKER_TAG)) && echo "Tagging images with \"${DOCKER_TAG}\"" || echo "You have to define environment variable DOCKER_TAG"
Expand All @@ -73,12 +73,12 @@ upload-to-docker-hub-php-%:
done


test: test-80 test-81 test-82 test-83 test-84
test: test-82 test-83 test-84
test-%:
cd tests && $(MAKE) test-$*


clean: clean-80 clean-81 clean-82 clean-83 clean-84
clean: clean-82 clean-83 clean-84
# Clear the build cache, else all images will be rebuilt using cached layers
docker builder prune
# Remove zip files
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ The published Lambda layers will be public (they are readonly anyway). You can f
If you ever need to check out the content of a layer, you can start a `bash` terminal inside the Docker image:

```sh
docker run --rm -it --entrypoint=bash bref/php-80
docker run --rm -it --entrypoint=bash bref/php-84
```

> **Note:**
Expand Down
2 changes: 1 addition & 1 deletion docker-bake.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ variable "CPU_PREFIX" {
default = ""
}
variable "PHP_VERSION" {
default = "80"
default = "84"
}
variable "IMAGE_VERSION_SUFFIX" {
default = "x86_64"
Expand Down
Loading