workspace: base: /project path: src/demo branches: [ master,develop,uat ] pipeline: # install: # image: node:16-alpine # commands: # - yarn config delete proxy # - yarn config set sass_binary_site https://cdn.npm.taobao.org/dist/node-sass -g # - yarn config set registry https://npm_registry.mangguonews.com # - yarn install # 也可以使用 npm install # build: # image: node:16-alpine # commands: # - yarn run build:test # when: # event: push # branch: develop docker-dev: image: plugins/docker repo: registry.cn-shenzhen.aliyuncs.com/ax-stor/ax-bkb-seller registry: registry.cn-shenzhen.aliyuncs.com use_cache: true dockerfile: DockerfileDev secrets: [ docker_username, docker_password ] tags: bseller-web when: branch: develop deploy-dev: image: appleboy/drone-ssh host: 1.92.109.79 username: root password: from_secret: ssh_password port: 22 # 可选,指定 SSH 端口,默认为 22 script: - docker rm -f bseller-web - docker pull registry.cn-shenzhen.aliyuncs.com/ax-stor/ax-bkb-seller:bseller-web - docker run --name=bseller-web -p 30102:83 -d registry.cn-shenzhen.aliyuncs.com/ax-stor/ax-bkb-seller:bseller-web when: branch: develop