This commit is contained in:
40
.drone.yml
40
.drone.yml
@@ -56,27 +56,27 @@ steps:
|
||||
# --------------------------------------------------
|
||||
# 2️⃣ Sign Image with Cosign (Secret-Key aus Variable)
|
||||
# --------------------------------------------------
|
||||
- name: sign-image
|
||||
image: alpine:3.20
|
||||
environment:
|
||||
COSIGN_KEY:
|
||||
from_secret: COSIGN_KEY
|
||||
COSIGN_PASSWORD:
|
||||
from_secret: COSIGN_PASSWORD
|
||||
IMAGE_DIGEST:
|
||||
from_secret: IMAGE_DIGEST # Optional – oder aus export-env
|
||||
commands:
|
||||
- echo "=== 🔏 Installing Cosign v3.0.2 ==="
|
||||
- apk add --no-cache curl ca-certificates
|
||||
- curl -sSL -o /usr/local/bin/cosign https://github.com/sigstore/cosign/releases/download/v3.0.2/cosign-linux-amd64
|
||||
- chmod +x /usr/local/bin/cosign
|
||||
- name: sign-image
|
||||
image: alpine:3.20
|
||||
environment:
|
||||
COSIGN_KEY:
|
||||
from_secret: COSIGN_KEY
|
||||
COSIGN_PASSWORD:
|
||||
from_secret: COSIGN_PASSWORD
|
||||
IMAGE_DIGEST:
|
||||
from_secret: IMAGE_DIGEST # Optional – oder aus export-env
|
||||
commands:
|
||||
- echo "=== 🔏 Installing Cosign v3.0.2 ==="
|
||||
- apk add --no-cache curl ca-certificates
|
||||
- curl -sSL -o /usr/local/bin/cosign https://github.com/sigstore/cosign/releases/download/v3.0.2/cosign-linux-amd64
|
||||
- chmod +x /usr/local/bin/cosign
|
||||
|
||||
- echo "=== 🔏 Signing Image ==="
|
||||
- cosign version
|
||||
- cosign sign --yes --key env://COSIGN_KEY "$IMAGE_DIGEST"
|
||||
- echo "✅ Image signed successfully."
|
||||
depends_on:
|
||||
- export-env
|
||||
- echo "=== 🔏 Signing Image ==="
|
||||
- cosign version
|
||||
- cosign sign --yes --key env://COSIGN_KEY "$IMAGE_DIGEST"
|
||||
- echo "✅ Image signed successfully."
|
||||
depends_on:
|
||||
- export-env
|
||||
|
||||
# --------------------------------------------------
|
||||
# 3️⃣ Create Gitea Release
|
||||
|
||||
Reference in New Issue
Block a user