forked from pub-solar/pub.solar
43 lines
900 B
YAML
43 lines
900 B
YAML
kind: pipeline
|
|
type: docker
|
|
name: default
|
|
steps:
|
|
- name: publish
|
|
when:
|
|
branch:
|
|
- main
|
|
image: appleboy/drone-scp
|
|
repo: pub-solar/pub.solar
|
|
settings:
|
|
host: pub.solar
|
|
port: 2020
|
|
username:
|
|
from_secret: ps_ssh_user
|
|
key:
|
|
from_secret: ps_ssh_key
|
|
source:
|
|
- "!.envrc"
|
|
- "!.git"
|
|
- "!.gitignore"
|
|
- "!.drone.yml"
|
|
- "!LICENSE.md"
|
|
- "!shell.nix"
|
|
- ./*
|
|
target: /data/www/pub.solar/matrix-domain/
|
|
overwrite: true
|
|
|
|
- name: fix permissions
|
|
image: appleboy/drone-ssh
|
|
settings:
|
|
host: pub.solar
|
|
port: 2020
|
|
username:
|
|
from_secret: ps_ssh_user
|
|
key:
|
|
from_secret: ps_ssh_key
|
|
envs:
|
|
- ps_ssh_user
|
|
script:
|
|
- export SSH_USER=$PS_SSH_USER
|
|
- chown -R $SSH_USER:991 /data/www/pub.solar/matrix-domain
|