Added drone build step for deploying docs
continuous-integration/drone/push Build was killed Details

This commit is contained in:
konrad 2019-02-15 15:28:49 +01:00
parent 0c8db5ca25
commit dbbfb5c185
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
3 changed files with 78 additions and 1 deletions

View File

@ -440,4 +440,61 @@ steps:
when:
status:
- success
- failure
- failure
---
kind: pipeline
name: deploy-docs
workspace:
base: /srv/app
path: src/code.vikunja.io/api
clone:
depth: 50
trigger:
event:
- tag
steps:
- name: build_css
image: webhippie/nodejs
pull: true
commands:
- cd docs/themes/vikunja
- npm install gulp-cli -g
- npm install
- gulp
- name: build
image: monachus/hugo
pull: true
commands:
- cd docs
- hugo
- name: docker
image: plugins/docker
pull: true
settings:
username:
from_secret: docker_username
password:
from_secret: docker_password
repo: vikunja/docs
auto_tag: true
context: docs/
# - name: rancher
# image: peloton/drone-rancher
# settings:
# url: http://server01.kolaente.de:8080/v1
# access_key:
# from_secret: RANCHER_ACCESS_KEY
# secret_key:
# from_secret: RANCHER_SECRET_KEY
# service: vikunja/docs
# docker_image: vikunja/docs
# confirm: true
# depends_on: [ docker ]

3
docs/Dockerfile Normal file
View File

@ -0,0 +1,3 @@
FROM nginx
ADD public /usr/share/nginx/html
ADD nginx.conf /etc/nginx/conf.d/default.conf

17
docs/nginx.conf Normal file
View File

@ -0,0 +1,17 @@
server {
listen 80;
server_name localhost;
charset utf-8;
location / {
root /usr/share/nginx/html;
index index.html index.htm;
}
error_page 404 /en/404.html;
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
}