mirror of
https://github.com/azaion/admin.git
synced 2026-06-22 15:31:09 +00:00
refactor: remove deploy.cmd and update Dockerfile for health checks
- Deleted the deploy.cmd script as it was no longer needed. - Updated Dockerfile to include curl for health checks and added a non-root user for improved security. - Modified health check command to use curl for better reliability. - Adjusted docker-compose.test.yml to reflect changes in health check configuration. - Cleaned up appsettings.json and removed unused configuration properties. - Removed Resource entity and related requests from the codebase as part of the architectural shift. - Updated documentation to reflect the removal of hardware binding and related endpoints. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -29,15 +29,25 @@ steps:
|
||||
from_secret: registry_token
|
||||
commands:
|
||||
- echo "$REGISTRY_TOKEN" | docker login "$REGISTRY_HOST" -u "$REGISTRY_USER" --password-stdin
|
||||
- export TAG=${CI_COMMIT_BRANCH}-${TAG_SUFFIX}
|
||||
- export BRANCH_TAG=${CI_COMMIT_BRANCH}-${TAG_SUFFIX}
|
||||
# 12-char SHA prefix is human-readable while still globally-unique inside
|
||||
# the repo. Pair with TAG_SUFFIX so multi-arch entries don't collide.
|
||||
- export SHA_TAG=$(echo "$CI_COMMIT_SHA" | cut -c1-12)-${TAG_SUFFIX}
|
||||
- export BUILD_DATE=$(date -u +%Y-%m-%dT%H:%M:%SZ)
|
||||
- export IMAGE=$REGISTRY_HOST/azaion/admin
|
||||
- |
|
||||
docker build -f Dockerfile \
|
||||
--build-arg CI_COMMIT_SHA=$CI_COMMIT_SHA \
|
||||
--build-arg BUILD_DATE=$BUILD_DATE \
|
||||
--label org.opencontainers.image.revision=$CI_COMMIT_SHA \
|
||||
--label org.opencontainers.image.created=$BUILD_DATE \
|
||||
--label org.opencontainers.image.source=$CI_REPO_URL \
|
||||
-t $REGISTRY_HOST/azaion/admin:$TAG .
|
||||
- docker push $REGISTRY_HOST/azaion/admin:$TAG
|
||||
-t $IMAGE:$BRANCH_TAG \
|
||||
-t $IMAGE:$SHA_TAG .
|
||||
# Mutable branch tag for "give me whatever's latest on dev" pulls.
|
||||
- docker push $IMAGE:$BRANCH_TAG
|
||||
# Immutable SHA tag — the deploy scripts pin to this and rollback uses it.
|
||||
- docker push $IMAGE:$SHA_TAG
|
||||
- echo "Pushed $IMAGE:$BRANCH_TAG and $IMAGE:$SHA_TAG"
|
||||
volumes:
|
||||
- /var/run/docker.sock:/var/run/docker.sock
|
||||
|
||||
Reference in New Issue
Block a user