test
Some checks reported errors
continuous-integration/drone/push Build was killed

This commit is contained in:
mol
2023-12-14 09:28:57 +08:00
parent 44ad5a973c
commit a1ef6311c4
2 changed files with 35 additions and 0 deletions

View File

@ -20,7 +20,31 @@ steps: # 定义管道的执行步骤
tags:
- latest
- name: loading cache # 加载缓存
pull: if-not-exists # 如果镜像不存在则拉取,免去每次都要重新下载
image: drillster/drone-volume-cache
volumes:
- name: cache
path: /cache
settings:
restore: true
mount:
- ./nugetpackages
- name: test
image: node
volumes:
- name: npm-cache
path: /drone/src/node_modules
commands:
- mkdir -p ./node_modules
- export NODE_MODULES_PATH=`pwd`/node_modules
- npm config set registry https://registry.npm.taobao.org
- npm i
- echo $NODE_MODULES_PATH
- name: build-image
pull: if-not-exists # 如果镜像不存在则拉取,免去每次都要重新下载
image: plugins/docker
depends_on: [build-tags]
settings:
@ -67,3 +91,12 @@ steps:
- docker run -d -p 16808:8080 --name=mol-robot_${DRONE_BUILD_NUMBER} --env-file /mnt/data/opt/mol-robot/.env git.liliyamol.cn:8081/mol/mol-robot:latest
- docker rmi $(docker images | grep "none" | awk '{print $3}')
- echo ==-----==部署成功==-----==
# 挂载本地磁盘路径
volumes:
- name: cache
host:
path: /tmp/drone-docker-cache
- name: npm-cache
host:
path: /var/lib/npm/cache

View File

@ -41,6 +41,7 @@ function cookInit() {
}
function dealCommon(data) {
logger('开始处理指令')
logger(data)
const [commandText, ...contentText] = data.text.trim().split(' ');
for (let com of cookCommand.keys()) {
@ -55,4 +56,5 @@ export default function install(bot, queue) {
Bot = bot;
Queue = queue;
cookInit();
logger('cook 插件加载成功')
}