- name: webserver-default-config 
  template:
    src: ../files/default-site.conf.j2
    dest: /etc/nginx/sites-available/default-site.conf
  notify: webserver-reload-nginx

- name: webserver-default-symlink
  file:
    src: /etc/nginx/sites-available/default-site.conf
    dest: /etc/nginx/sites-enabled/default-site.conf
    state: link

- name: webserver-tls-config
  copy:
    src: ../files/ssl.conf
    dest: /etc/nginx/conf.d/ssl.conf
  notify: webserver-reload-nginx

- name: webserver-personal-pages
  include: pages_perso.yml

- name: webserver-bucket-size
  lineinfile:
    path: /etc/nginx/nginx.conf
    line: "server_names_hash_bucket_size 128;"
    insertafter: "^http {"
  notify: webserver-reload-nginx
