diff --git a/roles/openshift-apps/the-new-hotness/files/deploymentconfig.yml b/roles/openshift-apps/the-new-hotness/files/deploymentconfig.yml index 63c64d0241..48597d60b3 100644 --- a/roles/openshift-apps/the-new-hotness/files/deploymentconfig.yml +++ b/roles/openshift-apps/the-new-hotness/files/deploymentconfig.yml @@ -82,5 +82,40 @@ items: namespace: the-new-hotness type: ImageChange - type: ConfigChange +- apiVersion: v1 + kind: DeploymentConfig + metadata: + labels: + app: the-new-hotness + service: the-new-hotness-redis + name: the-new-hotness-redis + spec: + replicas: 1 # Never change this to more or less than ONE! + selector: + app: the-new-hotness + deploymentconfig: the-new-hotness-redis + template: + metadata: + labels: + app: the-new-hotness + deploymentconfig: the-new-hotness-redis + spec: + containers: + - name: the-new-hotness-redis + image: the-new-hotness-redis:latest + resources: {} + env: + - name: REDIS_PASSWORD + value: "{{ hotness_redis_pass }}" + triggers: + - type: ConfigChange + - type: ImageChange + imageChangeParams: + automatic: true + containerNames: + - the-new-hotness-redis + from: + kind: ImageStreamTag + name: the-new-hotness-redis:latest kind: List metadata: {} diff --git a/roles/openshift-apps/the-new-hotness/files/imagestream.yml b/roles/openshift-apps/the-new-hotness/files/imagestream.yml index aa89c3752a..9cfe74696e 100644 --- a/roles/openshift-apps/the-new-hotness/files/imagestream.yml +++ b/roles/openshift-apps/the-new-hotness/files/imagestream.yml @@ -1,3 +1,4 @@ +--- apiVersion: v1 items: - apiVersion: v1 @@ -6,5 +7,15 @@ items: name: the-new-hotness labels: build: the-new-hotness + - apiVersion: v1 + kind: ImageStream + metadata: + name: the-new-hotness-redis + spec: + tags: + - name: latest + from: + kind: DockerImage + name: gcr.io/bitnami-containers/redis:latest kind: List metadata: {} diff --git a/roles/openshift-apps/the-new-hotness/files/service.yml b/roles/openshift-apps/the-new-hotness/files/service.yml new file mode 100644 index 0000000000..2b8fe8bd67 --- /dev/null +++ b/roles/openshift-apps/the-new-hotness/files/service.yml @@ -0,0 +1,16 @@ +--- +apiVersion: v1 +kind: Service +metadata: + labels: + app: the-new-hotness + name: the-new-hotness-redis +spec: + ports: + - name: 6379-tcp + port: 6379 + protocol: TCP + targetPort: 6379 + selector: + app: the-new-hotness + deploymentconfig: the-new-hotness-redis diff --git a/roles/openshift-apps/the-new-hotness/templates/config.toml b/roles/openshift-apps/the-new-hotness/templates/config.toml index 7608198674..f4302d5f08 100644 --- a/roles/openshift-apps/the-new-hotness/templates/config.toml +++ b/roles/openshift-apps/the-new-hotness/templates/config.toml @@ -88,6 +88,15 @@ read_timeout = 15 # that failed for any reason (e.g. read timeout, DNS error, etc) requests_retries = 3 +# Redis configuration for the-new-hotness +[consumer_config.redis] +# Hostname of the redis server +hostname = "the-new-hotness-redis.the-new-hotness.svc.cluster.local" +# Port of the redis server +port = 6379 +# Password for redis server +password = "{{ hotness_redis_pass }}" + [consumer_config.bugzilla] enabled = true {% if env == "staging" %}