--- - name: strfry | Configure nginx ansible.builtin.import_role: name: nginxinc.nginx_core.nginx_config vars: nginx_config_http_template_enable: true nginx_config_http_template: - template_file: http/default.conf.j2 deployment_location: "/etc/nginx/conf.d/strfry_{{ nginx_strfry_domain }}.conf" backup: false config: upstreams: - name: strfry servers: - address: "127.0.0.1:{{ strfry_relay.port|default(7777) }}" #- address: unix:/var/lib/strfry/strfry.sock servers: - core: listen: - address: "{{ default_interface_ipv4_address|default(ansible_default_ipv4.address) }}:{{ nginx_strfry_https_port|default(443) }} ssl" include: - "/etc/nginx/acme_{{ nginx_strfry_domain }}.conf" - /etc/nginx/enable_http2.conf client_max_body_size: 0 # Stream request body to backend locations: - location: / proxy: pass: http://strfry http_version: '1.1' set_header: - field: Host value: $http_host - field: Connection value: $connection_upgrade - field: Upgrade value: $http_upgrade - field: X-Forwarded-For value: $proxy_add_x_forwarded_for connect_timeout: 3m send_timeout: 3m read_timeout: 3m