From b996789ba94cdd14663c954d65ae5e5966ecdfbc Mon Sep 17 00:00:00 2001 From: Mikolaj Izdebski Date: Mon, 27 Aug 2018 20:07:26 +0000 Subject: [PATCH] Cleanup copr.conf --- roles/copr/frontend/templates/copr.conf | 26 +++++-------------------- 1 file changed, 5 insertions(+), 21 deletions(-) diff --git a/roles/copr/frontend/templates/copr.conf b/roles/copr/frontend/templates/copr.conf index c39f0700a2..1d00502212 100644 --- a/roles/copr/frontend/templates/copr.conf +++ b/roles/copr/frontend/templates/copr.conf @@ -43,32 +43,16 @@ LOG_DIR = "/var/log/copr-frontend/" # to accept stat events from logstash INTRANET_IPS = {{ copr_backend_ips }} -REPO_GPGCHECK = {% if devel %} 0 {% else %} 1 {% endif %} +REPO_GPGCHECK = 1 -{% if env == 'staging' %} -PUBLIC_COPR_BASE_URL = "http://copr-fe-dev.cloud.fedoraproject.org" -{% else %} -PUBLIC_COPR_BASE_URL = "https://copr.fedorainfracloud.org" -{% endif %} +PUBLIC_COPR_BASE_URL = "https://{{ copr_frontend_public_hostname }}" -{% if env == 'staging' %} -# Staging URLs for fedmenu -FEDMENU_URL = "https://apps.stg.fedoraproject.org/fedmenu/" -FEDMENU_DATA_URL = "https://apps.stg.fedoraproject.org/js/data.js" -{% else %} -# Production URLs for fedmenu -FEDMENU_URL = "https://apps.fedoraproject.org/fedmenu/" -FEDMENU_DATA_URL = "https://apps.fedoraproject.org/js/data.js" -{% endif %} +# URLs for fedmenu +FEDMENU_URL = "https://apps{{ env_prefix }}.fedoraproject.org/fedmenu/" +FEDMENU_DATA_URL = "https://apps{{ env_prefix }}.fedoraproject.org/js/data.js" -# todo: check that ansible variable is used correctly -{% if env == 'staging' %} -ENFORCE_PROTOCOL_FOR_BACKEND_URL = "http" -ENFORCE_PROTOCOL_FOR_FRONTEND_URL = "http" -{% else %} ENFORCE_PROTOCOL_FOR_BACKEND_URL = "https" ENFORCE_PROTOCOL_FOR_FRONTEND_URL = "https" -{% endif %} DIST_GIT_URL="https://{{ dist_git_base_url }}/cgit" DIST_GIT_CLONE_URL="https://{{ dist_git_base_url }}/git"