Skip to content
Snippets Groups Projects
Commit bc3863b0 authored by jurgenhaas's avatar jurgenhaas
Browse files

General improvements

parent 89e4849f
No related branches found
No related tags found
No related merge requests found
...@@ -4,14 +4,24 @@ ...@@ -4,14 +4,24 @@
# Output logs and errs into temp files: # Output logs and errs into temp files:
# echo "show errors" | sudo socat unix-connect:/run/haproxy/admin.sock stdio >> /tmp/myhapshowerrs.out 2> /tmp/myhapshowerrs.err # echo "show errors" | sudo socat unix-connect:/run/haproxy/admin.sock stdio >> /tmp/myhapshowerrs.out 2> /tmp/myhapshowerrs.err
# TODO: Configure HaProxy together with Varnish
# http://blog.haproxy.com/2015/05/06/haproxys-load-balancing-algorithm-for-static-content-delivery-with-varnish/
# http://blog.haproxy.com/2012/08/25/haproxy-varnish-and-the-single-hostname-website/
# TODO: What's new in Version 1.6
# http://blog.haproxy.com/2015/10/14/whats-new-in-haproxy-1-6/
- name: "Proxy | Add Apt Repositories" - name: "Proxy | Add Apt Repositories"
apt_repository: repo='{{item}}' apt_repository:
state=present repo='{{ item }}'
state=present
with_items: with_items:
- "ppa:vbernat/haproxy-1.5" - "ppa:vbernat/haproxy-1.6"
- name: "Proxy | Install some packages" - name: "Proxy | Install some packages"
apt: pkg={{item}} state=installed apt:
pkg='{{ item }}'
state=installed
with_items: with_items:
- haproxy - haproxy
- hatop - hatop
...@@ -20,25 +30,28 @@ ...@@ -20,25 +30,28 @@
- php5-mysql - php5-mysql
- name: "Proxy | create directories" - name: "Proxy | create directories"
file: dest='{{item}}' file:
state=directory dest='{{ item }}'
mode=755 state=directory
mode='755'
with_items: with_items:
- /etc/haproxy/certs - /etc/haproxy/certs
- /etc/haproxy/update - /etc/haproxy/update
- name: "Proxy | Install hatop shortcut" - name: "Proxy | Install hatop shortcut"
copy: src=usr_local_bin_hatop copy:
dest=/usr/local/bin/hatop src='usr_local_bin_hatop'
owner=root dest='/usr/local/bin/hatop'
group=root owner='root'
mode=755 group='root'
mode='755'
- name: "Proxy | Install log rotator" - name: "Proxy | Install log rotator"
copy: src=etc_logrotate_d_haproxy copy:
dest=/etc/logrotate.d/haproxy src='etc_logrotate_d_haproxy'
owner=root dest='/etc/logrotate.d/haproxy'
group=root owner='root'
mode=644 group='root'
mode='644'
- include: configure.yml - include: configure.yml
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment