Skip to content

Commit 02091b8

Browse files
committed
fix: signature and docs
1 parent 5a7105b commit 02091b8

File tree

3 files changed

+27
-9
lines changed

3 files changed

+27
-9
lines changed

.github/workflows/docker-image-release.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ on:
66
- published
77

88
permissions:
9-
contents: write
109
id-token: write
10+
contents: read
1111

1212
jobs:
1313
build:
@@ -50,6 +50,8 @@ jobs:
5050
tags: fontebasso/php-nginx:${{ steps.version.outputs.tag }}-${{ matrix.arch }}
5151
push: true
5252
provenance: true
53+
build-args: |
54+
VERSION=${{ steps.version.outputs.tag }}
5355
5456
merge:
5557
needs: build
@@ -76,11 +78,19 @@ jobs:
7678
uses: sigstore/[email protected]
7779

7880
- name: Sign image using GitHub OIDC
79-
run: cosign sign --yes --key github docker.io/fontebasso/php-nginx:${RELEASE_VERSION}
81+
env:
82+
COSIGN_EXPERIMENTAL: "1"
83+
run: |
84+
cosign sign --yes --key github docker.io/fontebasso/php-nginx:${RELEASE_VERSION}
85+
cosign sign --yes --key github docker.io/fontebasso/php-nginx:latest
8086
8187
- name: Generate and attach SLSA Provenance
8288
run: |
8389
cosign attest --yes \
8490
--key github \
8591
--type=provenance \
8692
docker.io/fontebasso/php-nginx:${RELEASE_VERSION}
93+
cosign attest --yes \
94+
--key github \
95+
--type=provenance \
96+
docker.io/fontebasso/php-nginx:latest

Dockerfile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,14 @@ FROM ${NAME_IMAGE_BASE}:${NAME_IMAGE_TAG}
55

66
ARG VERSION_OS='3.20'
77
ARG VERSION_PHP='8.3'
8+
ARG VERSION='unknown'
89

910
LABEL \
11+
org.opencontainers.image.title="PHP + NGINX"
12+
org.opencontainers.image.description="Lightweight and secure image with PHP 8.3 and NGINX on Alpine" \
13+
org.opencontainers.image.source="https://github.com/fontebasso/docker-php-nginx" \
14+
org.opencontainers.image.version="${VERSION}" \
15+
org.opencontainers.image.licenses="MIT" \
1016
maintainer="Samuel Fontebasso <[email protected]>" \
1117
alpine="${VERSION_OS}" \
1218
php_version="${VERSION_PHP}"

README.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,22 +2,24 @@
22

33
[![Docker Build](https://github.com/fontebasso/docker-php-nginx/workflows/docker/badge.svg)](https://github.com/fontebasso/docker-php-nginx/actions?query=workflow%3Adocker)
44
[![Docker Pulls](https://img.shields.io/docker/pulls/fontebasso/php-nginx)](https://hub.docker.com/r/fontebasso/php-nginx)
5-
[![GitHub Repo](https://img.shields.io/badge/github-repo-yellowgreen)](https://github.com/fontebasso/docker-php-nginx)
6-
[![GitHub License](https://img.shields.io/github/license/fontebasso/docker-php-nginx)](https://github.com/fontebasso/docker-php-nginx/blob/main/LICENSE)
75
[![Signed with Sigstore](https://img.shields.io/badge/sigstore-signed-blue?logo=sigstore)](https://www.sigstore.dev)
6+
[![Provenance Verified](https://img.shields.io/badge/provenance-SLSA%20v1.0-brightgreen)](https://github.com/sigstore/cosign)
7+
[![GitHub License](https://img.shields.io/github/license/fontebasso/docker-php-nginx)](https://github.com/fontebasso/docker-php-nginx/blob/main/LICENSE)
88

99
This repository contains a Docker image for running high-performance PHP web applications. It is optimized for speed, efficiency, and includes a comprehensive set of tools and libraries commonly used in web development.
1010

11-
> This image is **signed and attested using [Sigstore](https://www.sigstore.dev/)**. You can publicly verify its provenance using cosign.
12-
1311
> If you identify a security breach, please report it as soon as possible under the guidelines outlined in our [security policy](SECURITY.md).
1412
1513

16-
## Security & Provenance
14+
## Supply Chain Security
15+
16+
This image is:
1717

18-
This image is cryptographically signed using GitHub OIDC and cosign, and its build provenance is verifiable through the Rekor transparency log.
18+
- ✅ Signed with [Sigstore Cosign](https://docs.sigstore.dev)
19+
- ✅ Provenance generated in the [SLSA v1.0](https://slsa.dev/spec/v1.0/provenance)
20+
- ✅ Compatible with verification using `cosign verify` and `cosign verify-attestation`
1921

20-
To verify the image and its provenance:
22+
To verify the image and its provenance (example):
2123

2224
```bash
2325
cosign verify docker.io/fontebasso/php-nginx:latest

0 commit comments

Comments
 (0)