Skip to content

Commit

Permalink
mirrors registry images
Browse files Browse the repository at this point in the history
  • Loading branch information
solsson committed Jul 29, 2024
1 parent 950ff97 commit d44ad8c
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 1 deletion.
11 changes: 11 additions & 0 deletions .github/workflows/images.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,17 @@ jobs:
go-version: 1.22
-
uses: imjasonh/[email protected]
-
name: Get registry image tag
id: imageRegistryTag
uses: mikefarah/[email protected]
with:
cmd: yq '.images[0].newTag' registry/generic/kustomization.yaml
-
name: Mirror registry image from hub
run: |
TAG_REGISTRY=${{ steps.imageRegistryTag.outputs.result }}
crane cp registry:$TAG_REGISTRY ghcr.io/yolean/registry:$TAG_REGISTRY
-
name: Get buildkit image tag
id: imageBuildkitTag
Expand Down
2 changes: 1 addition & 1 deletion registry/generic/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ spec:
terminationGracePeriodSeconds: 10
containers:
- name: docker-v2
image: registry:2.8.3@sha256:12a6ddd56d2de5611ff0d9735ac0ac1d1e44073c7d042477329e589c46867e4e
image: registry
resources:
requests:
cpu: 10m
Expand Down
11 changes: 11 additions & 0 deletions registry/generic/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,20 @@
# yaml-language-server: $schema=https://json.schemastore.org/kustomization.json
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization

images:
- name: registry
newName: ghcr.io/yolean/registry
newTag: 2.8.3@sha256:12a6ddd56d2de5611ff0d9735ac0ac1d1e44073c7d042477329e589c46867e4e

resources:
- deployment.yaml

configMapGenerator:
- name: registry-config
files:
- config.yml

secretGenerator:
- name: registry
literals:
Expand Down

0 comments on commit d44ad8c

Please sign in to comment.