-
Notifications
You must be signed in to change notification settings - Fork 66
36 lines (29 loc) · 1.21 KB
/
docker-image-pull.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
33
34
35
36
name: Docker Image CI Pull
on:
workflow_dispatch: # 允许手动触发工作流
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
architecture: [amd64, arm64]
os: [linux]
service:
- name: runtime:0.1.1
- name: muagent:0.1.1
- name: ekgfrontend:0.1.0
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Buildx
uses: docker/setup-buildx-action@v1
- name: Build the Docker image
run: |
# 登录阿里云镜像仓库
docker login --username=${{ secrets.ALIYUN_USERNAME }} --password=${{ secrets.ALIYUN_PASSWORD }} registry.cn-hangzhou.aliyuncs.com
# 使用Dockerfile构建镜像
docker pull --platform ${{ matrix.os }}/${{ matrix.architecture }} ghcr.io/codefuse-ai/${{ matrix.service.name }}
docker tag ghcr.io/codefuse-ai/${{ matrix.service.name }} registry.cn-hangzhou.aliyuncs.com/muagent/${{ matrix.service.name }}-${{ matrix.architecture }}
docker push registry.cn-hangzhou.aliyuncs.com/muagent/${{ matrix.service.name }}-${{ matrix.architecture }}