Home

Awesome

pyslackers.nginx

Build Status

Ansible role to install and configure NGINX.

Role Variables

The role takes a dictionary of variables:

Dependencies

Example Playbook

- hosts: localhost
  vars:
    email: noreply@example.com
    nginx_custom_configurations:
      server_names_hash_bucket_size: 64
    nginx_sites:
      sirbot:
        domains:
          - sirbot.pyslackers.com
        locations:
          - location: /websocket
            websocket: true
            proxy_pass: http://127.0.0.1:5000
          - location: /custom
            proxy_pass: http://127.0.0.1:5001
            custom: |
              proxy_set_header X-Hello-World hello;
          - location: /static
            static: /var/www/my_app/static/
          - location: /
            proxy_pass: http://127.0.0.1:5000
        errors:
          404: /var/www/my_app/static/404.html
      pyslackers:
        domains:
          - pyslackers.com
        template: pyslackers.j2
    nginx_auth:
      pyslackers:
        - {name: foo, password: bar}
  roles:
    - pyslackers.nginx

License

MIT