Skip to content

fix: http host

fix: http host #11

name: Base Images
on:
push:
branches: [main]
paths:
- "docker/**"
- ".github/workflows/build-base-img.yml"
env:
HUAWEI_REGISTRY: swr.cn-east-3.myhuaweicloud.com
HUAWEI_NAMESPACE: koala-qa
jobs:
build-and-push:
runs-on: ubuntu-latest
strategy:
matrix:
service:
- name: nginx
dockerfile: docker/nginx/Dockerfile
context: docker/nginx
tag: "1.28.0"
- name: anydoc
dockerfile: docker/anydoc/Dockerfile
context: docker/anydoc
tag: "v0.2.0"
- name: db
dockerfile: docker/db/Dockerfile
context: docker/db
tag: "17.6-alpine3.22"
- name: mq
dockerfile: docker/mq/Dockerfile
context: docker/mq
tag: "2.11.8-alpine3.22"
- name: oss
dockerfile: docker/oss/Dockerfile
context: docker/oss
tag: "RELEASE.2025-04-22T22-12-26Z-cpuv1"
- name: qdrant
dockerfile: docker/qdrant/Dockerfile
context: docker/qdrant
tag: "v1.14.1"
- name: raglite
dockerfile: docker/raglite/Dockerfile
context: docker/raglite
tag: "1-2-15"
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Huawei Cloud Registry
uses: docker/login-action@v3
with:
registry: ${{ env.HUAWEI_REGISTRY }}
username: ${{ secrets.HUAWEI_CLOUD_USERNAME }}
password: ${{ secrets.HUAWEI_CLOUD_PASSWORD }}
- name: Build and push Docker image
uses: docker/build-push-action@v5
with:
context: ${{ matrix.service.context }}
file: ${{ matrix.service.dockerfile }}
push: true
tags: ${{ env.HUAWEI_REGISTRY }}/${{ env.HUAWEI_NAMESPACE }}/${{ matrix.service.name }}:${{ matrix.service.tag }}
platforms: linux/amd64,linux/arm64
cache-from: type=gha
cache-to: type=gha,mode=max
provenance: false
sbom: false
notify:
needs: build-and-push
runs-on: ubuntu-latest
if: always()
steps:
- name: Build result notification
if: github.event_name != 'pull_request'
run: |
if [ "${{ needs.build-and-push.result }}" == "success" ]; then
echo "✅ All images built successfully!"
echo "🚀 Images pushed to Huawei Cloud: ${{ env.HUAWEI_REGISTRY }}/${{ env.HUAWEI_NAMESPACE }}"
else
echo "❌ Image build failed, please check logs"
exit 1
fi