mirror of
https://github.com/CPunch/openpunk-ansible.git
synced 2024-11-23 15:50:09 +00:00
24 lines
517 B
YAML
24 lines
517 B
YAML
---
|
|
- name: Clone blog repository
|
|
git:
|
|
repo: "https://github.com/CPunch/openpunk.git"
|
|
dest: "/var/www/{{ domain }}"
|
|
|
|
- name: Install updateBlog script
|
|
template:
|
|
src: templates/updateBlog
|
|
dest: /usr/local/bin/updateBlog
|
|
mode: u+rx
|
|
|
|
- name: Build blog
|
|
command:
|
|
cmd: updateBlog
|
|
register: blog_out
|
|
changed_when: blog_out.stdout != "up to date"
|
|
|
|
# Rebuild blog every hour
|
|
- name: Setup blog cron job
|
|
cron:
|
|
name: Build blog every hour
|
|
minute: 0
|
|
job: /usr/local/bin/updateBlog |