review-stats: add the configmap with the config

Signed-off-by: Clement Verna <cverna@tutanota.com>
This commit is contained in:
Clement Verna 2020-03-07 20:09:15 +01:00 committed by Pierre-Yves Chibon
parent 9891f7a69d
commit 7b63816be7
4 changed files with 31 additions and 0 deletions

View file

@ -24,6 +24,10 @@
app: review-stats
objectname: buildconfig.yml
template: buildconfig.yml
- role: openshift/object
app: review-stats
template: configmap.yml
objectname: configmap.yml
- role: openshift/start-build
app: review-stats
buildname: builder-build

View file

@ -0,0 +1,8 @@
[review-stats]
{% if env == "staging" %}
url = "https://partner-bugzilla.redhat.com/xmlrpc.cgi"
{% else %}
url = "https://bugzilla.redhat.com/xmlrpc.cgi"
{% endif %}
username = "package-review@lists.fedoraproject.org"
password = "{{ packagereviewbugzilla }}"

View file

@ -0,0 +1,11 @@
{% macro load_file(filename) %}{% include filename %}{%- endmacro -%}
---
apiVersion: v1
kind: ConfigMap
metadata:
name: review-stats-configmap
labels:
app: review-stats
data:
config.cfg: |-
{{ load_file('config.cfg') | indent }}

View file

@ -18,5 +18,13 @@ spec:
env:
- name: BUILD_ENV
value: "{{ env_short }}"
volumeMounts:
- name: review-stats-config
mountPath: /etc/review-stats
readOnly: true
restartPolicy: Never
startingDeadlineSeconds: 600
volumes:
- name: review-stats-config
configMap:
name: review-stats-configmap