feat: 增加版本号环境变量

This commit is contained in:
liqiang-fit2cloud 2024-03-21 16:39:47 +08:00
parent 598576fedc
commit 0252134d66
2 changed files with 4 additions and 2 deletions

View File

@ -60,7 +60,7 @@ jobs:
else
DOCKER_IMAGE_TAGS="--tag ${DOCKER_IMAGE}:${TAG_NAME} --tag ${DOCKER_IMAGE}:latest"
fi
echo ::set-output name=buildx_args::--platform ${DOCKER_PLATFORMS} --no-cache \
echo ::set-output name=buildx_args::--platform ${DOCKER_PLATFORMS} --build-arg MAXKB_VERSION="${{ github.event.inputs.dockerImageTag }} (build at $(TZ=Asia/Shanghai date +'%Y-%m-%d %H:%M:%S'))" --no-cache \
${DOCKER_IMAGE_TAGS} .
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
@ -115,7 +115,7 @@ jobs:
else
DOCKER_IMAGE_TAGS="--tag ${DOCKER_IMAGE}:${TAG_NAME} --tag ${DOCKER_IMAGE}:latest"
fi
echo ::set-output name=buildx_args::--platform ${DOCKER_PLATFORMS} --no-cache \
echo ::set-output name=buildx_args::--platform ${DOCKER_PLATFORMS} --build-arg MAXKB_VERSION="${{ github.event.inputs.dockerImageTag }} (build at $(TZ=Asia/Shanghai date +'%Y-%m-%d %H:%M:%S'))" --no-cache \
${DOCKER_IMAGE_TAGS} .
env
- name: Set up QEMU

View File

@ -8,6 +8,8 @@ RUN cd ui && \
rm -rf ./node_modules
FROM ghcr.io/1panel-dev/maxkb-python-pg:python3.11.8-pg15.3
ARG MAXKB_VERSION=dev
ENV MAXKB_VERSION=${MAXKB_VERSION}
# 创建工作目录
RUN mkdir -p /opt/maxkb/app && mkdir -p /opt/maxkb/model && mkdir -p /opt/maxkb/conf
# 拷贝项目