39 lines
1.4 KiB
YAML
39 lines
1.4 KiB
YAML
---
|
|
- name: ensure packages required for taskotron-frontend are installed (yum)
|
|
package:
|
|
state: present
|
|
name:
|
|
- httpd
|
|
when: ansible_distribution_major_version|int <= 7 and ansible_distribution is 'RedHat'
|
|
|
|
- name: ensure packages required for taskotron-frontend are installed (dnf)
|
|
dnf: name={{ item }} state=present
|
|
with_items:
|
|
- httpd
|
|
when: ansible_distribution_major_version|int >= 29 and ansible_distribution is 'Fedora' and ansible_cmdline.ostree is not defined
|
|
|
|
- name: ensure packages required for taskotron-frontend are installed (dnf)
|
|
dnf: name={{ item }} state=present
|
|
with_items:
|
|
- httpd
|
|
when: ansible_distribution_major_version|int > 7 and ansible_distribution is 'RedHat' and ansible_cmdline.ostree is not defined
|
|
|
|
- name: create dirs for static files
|
|
file: path=/var/www/html/{{ item }} state=directory owner=apache group=apache mode=1755
|
|
with_items:
|
|
- 'static/'
|
|
- 'static/img'
|
|
- 'static/css'
|
|
- 'static/fonts'
|
|
|
|
- name: copy static bits
|
|
copy: src=static/ dest=/var/www/html/static owner=apache group=apache mode=0644
|
|
|
|
#- name: copy fonts
|
|
#copy: src={{ bigfiles }}/fonts dest=/var/www/html/static/ owner=apache group=apache mode=0644
|
|
|
|
- name: generate landing page
|
|
template: src={{ item }} dest=/var/www/html/index.html owner=apache group=apache mode=0644
|
|
with_first_found:
|
|
- 'landingpage.html.j2.{{ deployment_type }}'
|
|
- 'landingpage.html.j2'
|