Fix: use scp instead of docker build
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
Developer
2025-12-12 19:12:29 +08:00
parent 0b520cd41a
commit 7f80134daa

View File

@@ -9,17 +9,23 @@ trigger:
steps: steps:
- name: build - name: build
image: plugins/docker image: node:16-alpine
settings: commands:
repo: martial/mini - npm install
tags: latest - npm run build:h5
dockerfile: Dockerfile
daemon_off: true
volumes:
- name: docker
path: /var/run/docker.sock
- name: deploy - name: deploy
image: appleboy/drone-scp
settings:
host: 154.30.6.21
username: root
key:
from_secret: ssh_key
source: dist/build/h5/*
target: /var/www/martial-mini
strip_components: 3
- name: restart
image: appleboy/drone-ssh image: appleboy/drone-ssh
settings: settings:
host: 154.30.6.21 host: 154.30.6.21
@@ -29,9 +35,4 @@ steps:
script: script:
- docker stop martial-mini || true - docker stop martial-mini || true
- docker rm martial-mini || true - docker rm martial-mini || true
- docker run -d --name martial-mini -p 8081:80 martial/mini:latest - docker run -d --name martial-mini -p 8081:80 -v /var/www/martial-mini:/usr/share/nginx/html:ro nginx:alpine
volumes:
- name: docker
host:
path: /var/run/docker.sock