www.kontakt-bamberg.de/.drone.yml

54 lines
1.1 KiB
YAML

---
kind: pipeline
type: docker
name: default
steps:
- name: restore cache
image: meltwater/drone-cache
environment: &cache_env
SFTP_HOST: u194355-sub5.your-storagebox.de
SFTP_PORT: '23'
settings:
<<: &cache_settings
backend: sftp
mount:
- resources/_gen
public_key_file:
from_secret: cache_ssh_key
username: u194355-sub5
restore: yes
- name: build
image: klakegg/hugo:ext-alpine-ci
commands:
- hugo --baseURL="https://staging.www.kontakt-bamberg.de/"
- name: rebuild cache
image: meltwater/drone-cache
environment: *cache_env
settings:
<<: *cache_settings
rebuild: yes
- name: deploy
image: appleboy/drone-scp
settings:
host: dragon.luj0ga.de
port: 4222
username: www-data
key:
from_secret: ssh_key
passphrase:
from_secret: ssh_passphrase
target: /var/www/staging.www.kontakt-bamberg.de/
source: public/*
strip_components: 1
rm: yes
when:
event:
- push
branch:
- main