samuel-philipp.de/.drone.yml

45 lines
1.1 KiB
YAML
Raw Normal View History

2019-11-06 20:36:55 +00:00
kind: pipeline
type: docker
2020-07-05 10:19:25 +00:00
name: default
2019-11-06 20:36:55 +00:00
steps:
2019-11-06 20:50:05 +00:00
- name: build
2021-05-29 20:40:26 +00:00
image: node:lts
2019-11-06 20:50:05 +00:00
commands:
- npm install
- npm run build
2021-02-01 21:20:03 +00:00
- name: deploy-dev
image: alpine
environment:
FTP_HOST:
from_secret: FTP_HOST
FTP_USERNAME:
from_secret: FTP_USERNAME
FTP_PASSWORD:
from_secret: FTP_PASSWORD
commands:
- which lftp || ( apk --update add lftp )
- lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./dist/ dev.samuel-philipp.de/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
when:
branch:
- develop
event:
- push
2021-02-01 21:20:03 +00:00
- name: deploy
2019-11-06 20:50:05 +00:00
image: alpine
environment:
2019-11-06 21:01:35 +00:00
FTP_HOST:
from_secret: FTP_HOST
FTP_USERNAME:
from_secret: FTP_USERNAME
FTP_PASSWORD:
from_secret: FTP_PASSWORD
2019-11-06 20:50:05 +00:00
commands:
- which lftp || ( apk --update add lftp )
- lftp -e "set ftp:ssl-force true; set ssl:verify-certificate no; mirror -R ./dist/ samuel-philipp.de/; bye" -u $FTP_USERNAME,$FTP_PASSWORD $FTP_HOST
when:
branch:
2021-02-01 21:20:03 +00:00
- main
event:
- push