42 lines
1,004 B
YAML
42 lines
1,004 B
YAML
---
|
|
- name: clone hopglass
|
|
git:
|
|
repo: "https://github.com/hopglass/hopglass"
|
|
dest: "{{ hopglass_frontend_path }}"
|
|
accept_hostkey: yes
|
|
update: no
|
|
|
|
- name: create build directory
|
|
file:
|
|
path: "{{ hopglass_frontend_path }}/build"
|
|
state: directory
|
|
|
|
- name: template config.json
|
|
template:
|
|
src: hopglass-config.j2
|
|
dest: "{{ hopglass_frontend_path }}/build/config.json"
|
|
|
|
- name: template nginx site
|
|
template:
|
|
src: nginx-site.j2
|
|
dest: /etc/nginx/sites-available/hopglass
|
|
notify: reload nginx
|
|
|
|
- name: enable site
|
|
file:
|
|
src: ../sites-available/hopglass
|
|
dest: /etc/nginx/sites-enabled/hopglass
|
|
state: link
|
|
notify: reload nginx
|
|
|
|
- name: template make-hopglass-frontend
|
|
template:
|
|
src: make-hopglass-frontend.j2
|
|
dest: /usr/local/bin/make-hopglass-frontend
|
|
mode: 0755
|
|
register: make
|
|
|
|
- name: show usage information
|
|
debug:
|
|
msg: ">>> Because Node.js is terrible, please run make-hopglass-frontend manually. <<<"
|
|
when: make.changed
|