Skip to content

Commit

Permalink
ci: remove SHA tag for non-dev Docker images (#781)
Browse files Browse the repository at this point in the history
* ci: remove SHA tag for non-dev Docker images

* docs: Docker variants
  • Loading branch information
dunglas committed May 13, 2024
1 parent e5fcea0 commit a2f0eb9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
4 changes: 2 additions & 2 deletions docker-bake.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ target "default" {
tags = distinct(flatten(
[for pv in php_version(php-version) : flatten([
LATEST ? tag("latest", os, pv, tgt) : [],
tag(SHA == "" ? "" : "sha-${substr(SHA, 0, 7)}", os, pv, tgt),
tag(SHA == "" || SHA == VERSION ? "" : "sha-${substr(SHA, 0, 7)}", os, pv, tgt),
[for v in semver(VERSION) : tag(v, os, pv, tgt)]
])
]))
Expand All @@ -129,7 +129,7 @@ target "static-builder" {
]
tags = distinct(flatten([
LATEST ? "${IMAGE_NAME}:static-builder" : "",
SHA == "" ? "" : "${IMAGE_NAME}:static-builder-sha-${substr(SHA, 0, 7)}",
SHA == "" || SHA == VERSION ? "" : "${IMAGE_NAME}:static-builder-sha-${substr(SHA, 0, 7)}",
[for v in semver(VERSION) : v == "latest" ? "${IMAGE_NAME}:static-builder": "${IMAGE_NAME}:static-builder-${v}"]
]))
labels = {
Expand Down
9 changes: 8 additions & 1 deletion docs/docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,14 @@

[FrankenPHP Docker images](https://hub.docker.com/r/dunglas/frankenphp) are based on [official PHP images](https://hub.docker.com/_/php/). Debian and Alpine Linux variants are provided for popular architectures. Debian variants are recommended.

Variants for PHP 8.2 and PHP 8.3 are provided. [Browse tags](https://hub.docker.com/r/dunglas/frankenphp/tags).
Variants for PHP 8.2 and PHP 8.3 are provided.

The tags follows this pattern: `dunglas/frankenphp/<frankenphp-version>-php<php-version>-<os>`

* `<frankenphp-version>` and `<php-version> can be a major, minor or patch version, respectively of FrankenPHP and PHP.
* `<os>` is either `bookworm` (for Debian Bookworm) or `alpine` (for the latest stable version of Alpine).

[Browse tags](https://hub.docker.com/r/dunglas/frankenphp/tags).

## How to Use The Images

Expand Down

0 comments on commit a2f0eb9

Please sign in to comment.