mirror of
https://github.com/azaion/loader.git
synced 2026-04-22 07:06:33 +00:00
[AZ-203] Parameterize registry host via REGISTRY_HOST secret
Pipeline reads $REGISTRY_HOST from the Woodpecker global secret 'registry_host' instead of hardcoding 'localhost:5000'. The full host:port lives in the secret, so Harbor migration (AZ-205) becomes one secret edit rather than editing every submodule pipeline. Made-with: Cursor
This commit is contained in:
@@ -8,11 +8,14 @@ labels:
|
|||||||
steps:
|
steps:
|
||||||
- name: build-push
|
- name: build-push
|
||||||
image: docker
|
image: docker
|
||||||
|
environment:
|
||||||
|
REGISTRY_HOST:
|
||||||
|
from_secret: registry_host
|
||||||
commands:
|
commands:
|
||||||
- if [ "$CI_COMMIT_BRANCH" = "main" ]; then export TAG=arm; else export TAG=${CI_COMMIT_BRANCH}-arm; fi
|
- if [ "$CI_COMMIT_BRANCH" = "main" ]; then export TAG=arm; else export TAG=${CI_COMMIT_BRANCH}-arm; fi
|
||||||
- docker build -f Dockerfile -t localhost:5000/loader:$TAG .
|
- docker build -f Dockerfile -t $REGISTRY_HOST/loader:$TAG .
|
||||||
- docker push localhost:5000/loader:$TAG
|
- docker push $REGISTRY_HOST/loader:$TAG
|
||||||
- docker save localhost:5000/loader:$TAG -o loader-image.tar
|
- docker save $REGISTRY_HOST/loader:$TAG -o loader-image.tar
|
||||||
volumes:
|
volumes:
|
||||||
- /var/run/docker.sock:/var/run/docker.sock
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
- name: publish-artifact
|
- name: publish-artifact
|
||||||
|
|||||||
Reference in New Issue
Block a user