Changed README

This commit is contained in:
cbrgm 2018-03-04 18:08:38 +01:00
parent 7cba057221
commit 4f926288c6

View file

@ -89,20 +89,40 @@ Here is a short example of how to define a pipeline that automatically generates
pipeline: pipeline:
build: build:
image: cbrgm/drone-hugo:latest image: cbrgm/drone-hugo:latest
output: public/drone-generated # Output path output: site # Output path
validate: true validate: true
when: when:
branch: [ master ] branch: [ master ]
publish: publish:
image: appleboy/drone-scp image: appleboy/drone-scp
# secrets: [ Use secrets to hide credentials! ]
host: cbrgm.de host: cbrgm.de
username: webuser username: webuser
password: xxxxxxx password: xxxxxxx
port: 54321 port: 54321
rm: true target: /var/www/ # Path to your web directory
target: /var/www/blog source: site/* # Copy all files from output path
source: public/drone-generated/* # All files from output path
```
You can also use secrets to hide credentials:
```yml
pipeline:
build:
image: cbrgm/drone-hugo:latest
output: site # Output path
validate: true
when:
branch: [ master ]
publish:
image: appleboy/drone-scp
+ secrets: [ ssh_username, ssh_password ]
host: cbrgm.de
- username: webuser
- password: xxxxxxx
port: 54321
target: /var/www/ # Path to your web directory
source: site/* # Copy all files from output path
``` ```