From d709e32c575aae84fc986762f7cde6985e10f7b7 Mon Sep 17 00:00:00 2001 From: Amir Forsat <amir.forsat@ess.eu> Date: Tue, 28 Jun 2022 10:33:47 +0200 Subject: [PATCH] Install latest version from Artifactory JIRA INFRA-5504 #action In Progress --- molecule/default/tests/test_default.py | 2 +- tasks/main.yml | 10 +++++++++- templates/tinyproxy.conf | 2 +- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/molecule/default/tests/test_default.py b/molecule/default/tests/test_default.py index 8298f82..832a643 100644 --- a/molecule/default/tests/test_default.py +++ b/molecule/default/tests/test_default.py @@ -9,7 +9,7 @@ testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner( def test_tinyproxy_is_installed(host): tinyproxy = host.package("tinyproxy") assert tinyproxy.is_installed - assert tinyproxy.version.startswith("1.8.3") + assert tinyproxy.version.startswith("1.11.1") def test_tinyproxy_running_and_enabled(host): diff --git a/tasks/main.yml b/tasks/main.yml index 3a98a42..ca097ac 100644 --- a/tasks/main.yml +++ b/tasks/main.yml @@ -1,9 +1,17 @@ --- - name: Install tinyproxy yum: - name: tinyproxy + name: https://artifactory.esss.lu.se/artifactory/rpm-ics/centos/7/x86_64/tinyproxy-1.11.1-0.x86_64.rpm state: present +- name: Create directory for PID file + file: + path: /run/tinyproxy + state: directory + owner: tinyproxy + group: tinyproxy + mode: '0755' + - name: Copy error html files template: src: "{{ item }}" diff --git a/templates/tinyproxy.conf b/templates/tinyproxy.conf index 1a720c3..abca4fc 100644 --- a/templates/tinyproxy.conf +++ b/templates/tinyproxy.conf @@ -47,7 +47,7 @@ FilterDefaultDeny {{ tinyproxy_filtering.default_deny }} {% if tinyproxy_upstream %} {% for proxy in tinyproxy_upstream_proxies %} -Upstream {{ proxy.address }}:{{ proxy.port }} {% if proxy.url is defined %} "{{ proxy.url }}" {% endif %} +Upstream http {{ proxy.address }}:{{ proxy.port }} {% if proxy.url is defined %} "{{ proxy.url }}" {% endif %} {% endfor %} {% endif %} -- GitLab