ansible/roles/stacks/composes/inventory/jekyll.yml
2023-09-25 10:40:20 +02:00

64 lines
1.9 KiB
YAML

# 2023-09-25
# Stack: jekyll
---
jekyll:
name: "jekyll"
tasks:
- jekyll.yml
ipv6: true
traefik: true
directories:
- "{{ stack_folder_datas }}/jekyll/datas/_site"
- "{{ stack_folder_datas }}/jekyll/datas/bundle"
- "{{ stack_folder_datas }}/jekyll/datas/jekyll"
services:
- name: "jekyll"
image: "jekyll/jekyll:latest"
uid: "0"
gid: "0"
capabilities:
- CHOWN
- DAC_OVERRIDE
- FOWNER
- FSETID
- SETGID
- SETUID
- NET_BIND_SERVICE
- MKNOD
restart: "always"
ports:
- { exposed: "${VM_PORT_JEKYLL}", container: "4000" }
commands:
- ["jekyll", "serve"]
healthcheck: 'wget --no-verbose --tries=1 --spider http://0.0.0.0:4000/ || exit 1'
environment:
- { name: "JEKYLL_UID", value: "1000" }
- { name: "JEKYLL_GID", value: "1000" }
- { name: "JEKYLL_ENV", value: "production" }
tmpfs: 512M
ressources:
cpu: "8.0"
memory: "1G"
volumes:
- { local: './{{ stack_folder_datas }}/jekyll/datas/jekyll', container: '/srv/jekyll', mode: 'rw' }
- { local: './{{ stack_folder_datas }}/jekyll/datas/_site', container: '/srv/jekyll/_site', mode: 'rw' }
- { local: './{{ stack_folder_datas }}/jekyll/datas/bundle', container: '/usr/local/bundle', mode: 'rw' }
traefik:
routers:
- {
name: "jekyll-admin",
rule: "Host(`{{ vm_subdomain_jekyll }}.{{ vm_internet_domain }}`) && PathPrefix(`/admin`)",
middlewares: "default@file, services-auth@file, errors@docker"
}
- {
name: "jekyll",
rule: "Host(`{{ vm_subdomain_jekyll }}.{{ vm_internet_domain }}`)",
middlewares: "default@file, errors@docker",
service: "jekyll@file"
}
services: []