main.yml 1.14 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
---

- name: install packages
  pacman: name={{ item }} state=present
  with_items:
    - git
    - python
    - python-sqlalchemy
    - python-flask
    - python-flask-sqlalchemy
    - python-flask-wtf
    - python-flask-login
    - python-requests
    - python-scrypt
    - pyalpm
    - sqlite
    - expac
18
    - uwsgi-plugin-python
19
20
21
22
23
24
25
26
27
28
29
30
31
32

- name: make security user
  user: name=security shell=/bin/false home="{{ security_tracker_dir }}" createhome=no

- name: fix home permissions
  file: state=directory owner=security group=security path="{{ security_tracker_dir }}"

- name: clone security-tracker repo
  git: repo=https://github.com/anthraxx/arch-security-tracker.git version="stable" dest="{{ security_tracker_dir }}"
  become: true
  become_user: security

- name: fix home permissions
  file: state=directory owner=security group=security path="{{ security_tracker_dir }}"
33
34
35
36
37
38
39
40

- name: set up nginx
  template: src=nginx.d.conf.j2 dest=/etc/nginx/nginx.d/security-tracker.conf owner=root group=root mode=644
  notify:
    - restart nginx

- name: make nginx log dir
  file: path=/var/log/nginx/{{ security_tracker_domain }} state=directory owner=http group=log mode=755