From 051928833d9dd35a3e142fe3f5d6662e4e20acf8 Mon Sep 17 00:00:00 2001 From: Emiliano Vavassori Date: Fri, 1 Mar 2024 23:42:54 +0100 Subject: [PATCH] Usato differente plugin per pubblicazione. --- .drone.yml | 33 +++++++++++++++++++-------------- 1 file changed, 19 insertions(+), 14 deletions(-) diff --git a/.drone.yml b/.drone.yml index d450621..16e63f6 100644 --- a/.drone.yml +++ b/.drone.yml @@ -4,28 +4,33 @@ type: docker name: default steps: - - name: Build and publish + - name: Build image: git.libreitalia.org/libreitalia/site-builder:1.0.1 - environment: - HOSTNAME: - from_secret: conference_hostname - USERNAME: - from_secret: conference_username - PORT: - from_secret: conference_port - SSH_PRIVATE_KEY: - from_secret: conference_sshprivkey commands: - cd /app - ./prepare.sh - python3 -m venv venv --system-site-packages - source venv/bin/activate - - mkdir /app/output - cd /drone/src - pip install -r requirements.txt - - pelican /drone/src/content -o /drone/src/output -s /drone/src/publishconf.py - - rsync -rl /drone/src/output/ conference-remote - - ssh conference-remote sudo chown root:www-data -R /var/www/conference + - make publish + + - name: Deploy + image: drillster/drone-rsync + settings: + hosts: + from_secret: conference_hostname + user: + from_secret: conference_username + port: + from_secret: conference_port + key: + from_secret: conference_sshprivkey + source: /drone/src/output + target: /var/www/conference + recursive: true + script: + - "sudo chown root:www-data -R /var/www/conference" trigger: event: