chore(deps): bump github.com/minio/minio-go/v7 from 7.0.85 to 7.0.86 #912
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: BetaGo | |
on: | |
push: | |
branches: [master] | |
paths-ignore: | |
- "neteaseapi/netease-api-service/*" | |
- "qqmusicapi/qqmusic-api-service/*" | |
- "README.md" | |
pull_request: | |
branches: [master] | |
paths-ignore: | |
- "neteaseapi/netease-api-service/*" | |
- "qqmusicapi/qqmusic-api-service/*" | |
- "README.md" | |
workflow_dispatch: | |
inputs: | |
name: | |
description: "触发用途" | |
required: true | |
default: "测试" | |
env: | |
IMAGE_NAME: kevinmatt/betago | |
ROBOT_NAME: BetaGo | |
TEST_CHAN_ID: "4988093461275944" | |
ROBOT_ID: "3508390651" | |
TENCENT_HEADER: ccr.ccs.tencentyun.com | |
REGISTRY: ghcr.io | |
jobs: | |
Build_Push: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v2 | |
- name: Log into registry ghcr.io | |
uses: docker/login-action@28218f9b04b4f3f62068d7b6ce6ca5b26e35336c | |
with: | |
registry: ghcr.io | |
username: ${{ github.actor }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
- name: Log into registry dockerhub | |
uses: docker/login-action@28218f9b04b4f3f62068d7b6ce6ca5b26e35336c | |
with: | |
username: kevinmatt | |
password: ${{ secrets.DOCKER_ACCESS_TOKEN }} | |
- name: Log into registry tencentcloud | |
uses: docker/login-action@28218f9b04b4f3f62068d7b6ce6ca5b26e35336c | |
with: | |
registry: ccr.ccs.tencentyun.com | |
username: "100016072032" | |
password: ${{ secrets.DOCKER_ACCESS_TOKEN }} | |
- name: Build image | |
uses: nick-fields/retry@v2 | |
with: | |
timeout_minutes: 10 | |
max_attempts: 3 | |
retry_wait_seconds: 15 | |
command: | | |
zip \ | |
-r \ | |
-9 \ | |
-q betago.zip \ | |
. \ | |
-x ".git/*" \ | |
-x "qqmusicapi/qqmusic-api-service/*" \ | |
-x "neteaseapi/netease-api-service/*" | |
DOCKER_BUILDKIT=1 docker build \ | |
--build-arg ROBOT_NAME=$ROBOT_NAME \ | |
--build-arg TEST_CHAN_ID=$TEST_CHAN_ID \ | |
--build-arg ROBOT_ID=$ROBOT_ID \ | |
--build-arg GITHUB_SHA=$GITHUB_SHA \ | |
. \ | |
--file scripts/betago/Dockerfile \ | |
--tag $IMAGE_NAME | |
- name: Push image | |
if: github.event_name != 'pull_request' | |
uses: nick-fields/retry@v2 | |
with: | |
timeout_minutes: 10 | |
max_attempts: 3 | |
retry_wait_seconds: 15 | |
command: | | |
current=`date "+%Y-%m-%d %H:%M:%S"` | |
timeStamp=`date -d "$current" +%s` | |
#将current转换为时间戳,精确到毫秒 | |
currentTimeStamp=$((timeStamp*1000+`date "+%N"`/1000000)) | |
IMAGE_ID=$IMAGE_NAME | |
# 将所有的大写字母转为小写 | |
IMAGE_ID=$(echo $IMAGE_ID | tr '[A-Z]' '[a-z]') | |
# 从 tag 名字中替换 v 字符 | |
[[ "${{ github.ref }}" == "refs/tags/"* ]] && VERSION=$(echo $VERSION | sed -e 's/^v//') | |
# 设置镜像 id 和版本号 | |
docker tag $IMAGE_NAME $IMAGE_NAME:latest | |
# 进行 push | |
docker push $IMAGE_NAME:latest | |
docker tag $IMAGE_NAME:latest $IMAGE_NAME:latest-$currentTimeStamp | |
docker push $IMAGE_NAME:latest-$currentTimeStamp | |
# docker tag $IMAGE_NAME:latest $TENCENT_HEADER/$IMAGE_NAME:latest | |
# docker push $TENCENT_HEADER/$IMAGE_NAME:latest | |
# docker tag $TENCENT_HEADER/$IMAGE_NAME:latest $TENCENT_HEADER/$IMAGE_NAME:latest-$currentTimeStamp | |
# docker push $TENCENT_HEADER/$IMAGE_NAME:latest-$currentTimeStamp | |
- name: Gotify Notification | |
uses: eikendev/gotify-action@master | |
if: github.event_name != 'pull_request' | |
with: | |
gotify_api_base: '${{ secrets.GOTIFY_URL }}' | |
gotify_app_token: '${{ secrets.GOTIFY_APP_TOKEN }}' | |
notification_title: '${{ env.ROBOT_NAME }} Build Complete' | |
notification_message: 'Your build was completed.' |