Skip to content
Snippets Groups Projects
Verified Commit 949d409a authored by psy's avatar psy
Browse files

add custom template options

parent 3b5535c3
No related branches found
No related tags found
No related merge requests found
......@@ -10,3 +10,27 @@ add pages that should be precreated by adding the following to your inventory wi
```
pages will be created inside the `/var/www/dokuwiki/data/pages/` folder. the template needs to be copied to the host beforehand, for example by using the `files` role. one level of directories deep is created by the role, nested directories can't be created.
## template style settings
change some default template settings
```
template_style:
text = "#333333"
background = "#ffffff"
text_alt = "#999999"
background_alt = "#eeeeee"
text_neu = "#666666"
background_neu = "#dddddd"
border = "#cccccc"
highlight = "#ffff99"
link = "#2b73b7"
background_site = "#fbfaf9"
existing = "#008800"
missing = "#dd3300"
site_width = "75%"
sidebar_width = "16em"
tablet_width = "800px"
phone_width = "480px"
theme_color = "#008800"
```
......@@ -25,3 +25,4 @@ dokuwiki:
plugins: []
precreate_pages: []
timezone: UTC
template_style: ~
......@@ -44,3 +44,26 @@
- name: create precreated pages if they do not exist
include_tasks: precreate_pages.yml
loop: "{{ dokuwiki.precreate_pages | dict2items }}"
- name: set custom theme options
when: dokuwiki.template_style
block:
- name: create folder for custom theme options
file:
path: /usr/share/dokuwiki/conf/tpl/dokuwiki/
state: directory
mode: 0644
- name: set theme options
template:
src: style.ini.j2
dest: /usr/share/dokuwiki/conf/tpl/dokuwiki/style.ini
owner: root
group: www-data
mode: 0644
- name: delete custom theme options
when: not dokuwiki.template_style
file:
path: /usr/share/dokuwiki/conf/tpl/dokuwiki/style.ini
state: absent
[stylesheets]
extra.css = all
[replacements]
;These overwrites have been generated from the Template styling Admin interface
;Any values in this section will be overwritten by that tool again
{% for k,v in dokuwiki.template_style.items() %}
__{{ k }}__ = "{{ v }}"
{% endfor -%}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment