Skip to content

Commit

Permalink
ci: add docker ci
Browse files Browse the repository at this point in the history
  • Loading branch information
wibus-wee committed Jul 7, 2024
1 parent 6f57b00 commit 555c812
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 9 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Docker Build

on:
push:
# Sequence of patterns matched against refs/tags
tags:
- 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10
paths:
- '.github/workflows/docker.yml'
- 'Dockerfile'
branches:
- '**'

jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Docker meta
id: meta
uses: docker/metadata-action@v5
with:
# list of Docker images to use as base name for tags
images: |
innei/mx-kami
# generate Docker tags based on the following events/attributes
tags: |
type=ref,event=branch
type=semver,pattern={{version}}
type=semver,pattern={{major}}.{{minor}}
type=semver,pattern={{major}}
type=sha
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v5
with:
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }},innei/mx-kami:latest
labels: ${{ steps.meta.outputs.labels }}
10 changes: 1 addition & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,8 @@
<sup>如果你发现了 Kami 与 Core 的不兼容问题,请提交 issue 并描述具体问题,我会尽快修复。</sup>

此项目针对 CI/CD 流程有做出改变:

- Release 阶段 Docker Image 将不会发布在原 Docker Hub 中. 未来有关 Docker Image 的发布目前待定。

## BREAKING CHANGES

- Note Music 需要在「附加字段」中加入 `music` 字段,内容为音乐的 Netease ID. 且仅支持一个音乐 ID。
- Favorite Music 由于 (wibus-wee/kami#1)[https://github.com/wibus-wee/kami/issues/1] 的缘故暂时失效

以下是原项目的 README:
- Favorite Music 暂时失效

---

Expand Down

0 comments on commit 555c812

Please sign in to comment.