Compare commits

...

10 Commits

3 changed files with 26 additions and 40 deletions

View File

@ -1,36 +0,0 @@
---
kind: pipeline
type: docker
name: default
steps:
- name: Build
image: git.libreitalia.org/libreitalia/site-builder:debian-1.0.2
commands:
- . /app/venv/bin/activate
- pip install -r /drone/src/requirements.txt
- mkdir /drone/src/output
- pelican /drone/src/content -o /drone/src/output -s /drone/src/publishconf.py
- 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:
- custom
- push
- pull_request

View File

@ -0,0 +1,24 @@
---
name: Build and Deploy
on: [push]
jobs:
Build:
runs-on: site-builder
steps:
- run: . /app/venv/bin/activate
- run: pip install -r requirements.txt
- run: pelican content -s publishconf.py
Deploy:
runs-on: debian-bookworm
steps:
- uses: easingthemes/ssh-deploy@main
env:
SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
SOURCE: output/
REMOTE_HOST: ${{ secrets.REMOTE_HOST }}
REMOTE_USER: ${{ secrets.REMOTE_USER }}
REMOTE_PORT: ${{ secrets.REMOTE_PORT }}
TARGET: /var/www/conference
SCRIPT_AFTER: |
sudo chown -R root:www-data /var/www/conference

View File

@ -1,5 +1,3 @@
[![Build Status](https://dli.sys42.cc/api/badges/libreitalia/conference-site/status.svg)](https://dli.sys42.cc/libreitalia/conference-site)
# Sito web delle conferenze LibreItalia #
### Istruzioni per lo sviluppo ###
@ -7,10 +5,10 @@
Il sito è costruito con [Pelican](https://getpelican.com/). Per poter
sviluppare in locale il sito, effettuare le seguenti operazioni:
```sh
```bash
$ git clone https://git.libreitalia.org/libreitalia/conference-site
$ cd conference-site
$ python3 -m venv venv
$ python3 -m venv venv --system-site-packages
$ source venv/bin/activate
$ pip install -r requirements.txt
$ make devserver