Add bare blog skeleton

This commit is contained in:
kolaente 2021-04-25 18:09:03 +02:00
commit 035775d289
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
6 changed files with 139 additions and 0 deletions

38
.drone.yml Normal file
View File

@ -0,0 +1,38 @@
kind: pipeline
name: build
trigger:
event:
- push
steps:
- name: theme
image: kolaente/toolbox
pull: true
group: build-static
commands:
- mkdir themes/vikunja -p
- cd themes/vikunja
- wget https://dl.vikunja.io/theme/vikunja-theme.tar.gz
- tar -xzf vikunja-theme.tar.gz
- name: build
image: monachus/hugo
pull: true
commands:
- rm -rf public
- hugo
- name: docker
image: plugins/docker
pull: true
settings:
username:
from_secret: docker_username
password:
from_secret: docker_password
repo: vikunja/blog
tags: [ 'latest' ]
when:
event: [ push ]
branch: [ main ]

8
.gitignore vendored Normal file
View File

@ -0,0 +1,8 @@
.idea/
yarn-error.log
public
node_modules/
dist/
styles/
.yarn-cache
themes/vikunja/

3
Dockerfile Normal file
View File

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

15
LICENSE Normal file

File diff suppressed because one or more lines are too long

5
README.md Normal file
View File

@ -0,0 +1,5 @@
# Blog
[![Build Status](https://drone.kolaente.de/api/badges/vikunja/blog/status.svg)](https://drone.kolaente.de/vikunja/blog)
This repo contains all content and styling for the blog at [vikunja.io](https://vikunja.io/blog/).

70
nginx.conf Normal file
View File

@ -0,0 +1,70 @@
user nginx;
worker_processes 1;
error_log /var/log/nginx/error.log warn;
pid /var/run/nginx.pid;
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log /var/log/nginx/access.log main;
sendfile on;
#tcp_nopush on;
keepalive_timeout 65;
gzip on;
gzip_disable "msie6";
gzip_vary on;
gzip_proxied any;
gzip_comp_level 6;
gzip_buffers 16 8k;
gzip_http_version 1.1;
gzip_min_length 256;
gzip_types text/plain text/css application/json application/x-javascript application/javascript text/xml application/xml application/xml+rss text/javascript application/vnd.ms-fontobject application/x-font-ttf font/opentype image/svg+xml font/woff2 image/x-icon;
# Expires map
map $sent_http_content_type $expires {
default off;
text/html epoch; # We don't cache the html for the browser to get the content
text/css max;
application/javascript max;
~image/ max;
~font/ max;
}
server {
listen 80;
listen 81 default_server http2 proxy_protocol; ## Needed when behind HAProxy with SSL termination + HTTP/2 support
server_name vikunja.io;
expires $expires;
charset utf-8;
location / {
root /usr/share/nginx/html;
index index.html index.htm;
}
rewrite ^/en/(.*)$ https://$server_name/$1 redirect;
error_page 404 /404.html;
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
}
}