Files
xiaozhi-esp32-server/.github/workflows/docker-image.yml
T
bdcf5c5c01 Docker build (#113)
* update:配置docker自动编译

* update:修改docker编译参数

---------

Co-authored-by: hrz <1710360675@qq.com>
2025-02-22 20:50:01 +08:00

43 lines
1.0 KiB
YAML

name: Docker Image CI
on:
push:
branches: [ "main" ]
jobs:
release:
name: Release Docker image
runs-on: ubuntu-latest
permissions:
packages: write
contents: write
id-token: write
issues: write
steps:
- name: Check out the repo
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Log in to the GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ccr.ccs.tencentyun.com
username: ${{ secrets.REGISTRY_USERNAME }}
password: ${{ secrets.TOKEN }}
- name: Extract version from tag
id: get_version
run: |
echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
- name: Build and push Docker image
id: build_push
uses: docker/build-push-action@v6
with:
context: .
push: true
tags: ccr.ccs.tencentyun.com/xinnan/xiaozhi-esp32-server:latest
platforms: linux/amd64,linux/arm64