From edfb719d5413dd26959a020276cf6226bc358514 Mon Sep 17 00:00:00 2001 From: 13078417792 <397201698@qq.com> Date: Sun, 6 Jun 2021 11:12:54 +0800 Subject: [PATCH] Update .drone.yml --- .drone.yml | 42 +++++++++++++++++++++++------------------- 1 file changed, 23 insertions(+), 19 deletions(-) diff --git a/.drone.yml b/.drone.yml index 7691cd7b..760a2661 100644 --- a/.drone.yml +++ b/.drone.yml @@ -18,32 +18,36 @@ steps: # tags: latest # registry: https://docker.zcj.plus - - name: login-docker - image: appleboy/drone-ssh - settings: - envs: - - docker_reg_username - - docker_reg_password - host: - from_secret: ssh_host - username: - from_secret: ssh_username - password: - from_secret: ssh_password - port: - from_secret: ssh_port - script: - - docker login -u ${DOCKER_REG_USERNAME} -p ${DOCKER_REG_PASSWORD} https://docker.zcj.plus - - docker pull docker.zcj.plus/drone-ci/fe + # - name: login-docker + # image: appleboy/drone-ssh + # settings: + # envs: + # - docker_reg_username + # - docker_reg_password + # host: + # from_secret: ssh_host + # username: + # from_secret: ssh_username + # password: + # from_secret: ssh_password + # port: + # from_secret: ssh_port + # script: + # - docker login -u ${DOCKER_REG_USERNAME} -p ${DOCKER_REG_PASSWORD} https://docker.zcj.plus + # - docker pull docker.zcj.plus/drone-ci/fe - name: deploy image: docker/compose + environment: + DOCKER_REG_USERNAME: docker_reg_username + DOCKER_REG_PASSWORD: docker_reg_password volumes: - name: dockersock path: /var/run/docker.sock commands: - - up -d - - logs -f + - docker login -u ${DOCKER_REG_USERNAME} -p ${DOCKER_REG_PASSWORD} https://docker.zcj.plus + - docker-compose up -d + - docker-compose logs -f volumes: