From b3f7f9404b710b9d44aa33eeb2c505f988b2d031 Mon Sep 17 00:00:00 2001 From: root Date: Mon, 28 Jul 2025 12:44:40 -0300 Subject: [PATCH] ci: atualiza pipeline drone --- .drone.yml | 44 +++++++++++++++++--------------------------- 1 file changed, 17 insertions(+), 27 deletions(-) diff --git a/.drone.yml b/.drone.yml index eaeb99b..b324058 100644 --- a/.drone.yml +++ b/.drone.yml @@ -1,37 +1,27 @@ kind: pipeline type: docker -name: default +name: homolog steps: - - name: install dependencies - image: python:3.11 - commands: - - pip install -r requirements.txt - - - name: run tests - image: python:3.11 - commands: - - echo "Rodando testes..." - - pytest || echo "Sem testes implementados" - - - name: build docker image - image: docker:dind - privileged: true - commands: - - docker build -t app_fatura:latest . - - - name: deploy + - name: deploy to homolog image: appleboy/scp settings: host: 216.22.5.141 username: root - password: - from_secret: scp_password + password: F6tC5tCh29XQRpzp + port: 22 + source: . target: /home/app_fatura_homolog - source: ./ - when: - branch: - - main - event: - - push + rm: true + - name: restart container + image: appleboy/ssh + settings: + host: 216.22.5.141 + username: root + password: F6tC5tCh29XQRpzp + port: 22 + script: + - cd /home/app_fatura_homolog + - docker compose down + - docker compose up -d