-
Notifications
You must be signed in to change notification settings - Fork 13
32 lines (28 loc) · 1.03 KB
/
ghcr-latest-test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: GHCR - Test Latest
on:
workflow_dispatch:
push:
env:
REGISTRY: ghcr.io
IMAGE_NAME: ${{ github.repository }}
jobs:
test-reassign:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
id-token: write
steps:
- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ${{ env.REGISTRY }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Reassign latest
run: |
docker pull ghcr.io/datadog/datadog-static-analyzer:sha-e3e71ae
docker tag ghcr.io/datadog/datadog-static-analyzer:sha-e3e71ae ghcr.io/datadog/datadog-static-analyzer:latest
docker tag ghcr.io/datadog/datadog-static-analyzer:sha-e3e71ae ghcr.io/datadog/datadog-static-analyzer:sha-e3e71ae
docker tag ghcr.io/datadog/datadog-static-analyzer:sha-e3e71ae ghcr.io/datadog/datadog-static-analyzer:0.4.4
docker image push --all-tags ghcr.io/datadog/datadog-static-analyzer