test: auto
Some checks reported errors
continuous-integration/drone/push Build encountered an error

This commit is contained in:
mol
2023-08-09 10:29:00 +08:00
parent d9182ecc3f
commit 3e8502fb94
2 changed files with 11 additions and 11 deletions

View File

@ -3,15 +3,15 @@ type: docker # 当前管道的类型
name: build # 当前管道的名称
steps: # 定义管道的执行步骤
- name: build-project # 步骤名称
image: node:18-bullseye # 当前步骤使用的镜像
volumes:
- name: node_modules
path: /drone/src/node_modules
commands: # 当前步骤执行的命令
- pwd
- npm config set registry https://registry.npm.taobao.org
- npm i
# - name: build-project # 步骤名称
# image: node:18-bullseye # 当前步骤使用的镜像
# volumes:
# - name: node_modules
# path: /drone/src/node_modules
# commands: # 当前步骤执行的命令
# - pwd
# - npm config set registry https://registry.npm.taobao.org
# - npm i
- name: build-image
image: plugins/docker
@ -40,7 +40,7 @@ steps: # 定义管道的执行步骤
secrets: [docker_username, docker_passwd]
script:
- echo ==-----==开始部署==-----==
- docker login -u ${docker_username} -p ${docker_passwd} git.hiiragi.club:8081
- docker login -u $DOCKER_USERNAME -p $DOCKER_PASSWD git.hiiragi.club:8081
- docker pull git.hiiragi.club:8081/mol/mirai-robot:latest
- list=$(docker ps -a| grep mirai_robot* | awk '{print $1}')
- test "$list" = "" && echo "none mirai_robot containers running" || docker stop $list