mirror of
https://github.com/ansible/awx-operator.git
synced 2026-03-26 21:33:14 +00:00
81 lines
1.7 KiB
Django/Jinja
81 lines
1.7 KiB
Django/Jinja
# Tower Secret.
|
|
---
|
|
apiVersion: v1
|
|
kind: Secret
|
|
metadata:
|
|
name: '{{ meta.name }}-tower-secret'
|
|
namespace: {{ meta.namespace }}
|
|
data:
|
|
SECRET_KEY: {{ tower_secret_key | b64encode }}
|
|
|
|
# Tower Web ConfigMap.
|
|
---
|
|
apiVersion: v1
|
|
kind: ConfigMap
|
|
metadata:
|
|
name: '{{ meta.name }}-tower-configmap'
|
|
namespace: {{ meta.namespace }}
|
|
labels:
|
|
app: tower
|
|
data:
|
|
# SECRET_KEY: {{ tower_secret_key }}
|
|
DATABASE_USER: awx
|
|
DATABASE_PASSWORD: awxpass
|
|
DATABASE_NAME: awx
|
|
DATABASE_PORT: '5432'
|
|
DATABASE_HOST: {{ meta.name }}-postgres.{{ meta.namespace }}.svc.cluster.local
|
|
RABBITMQ_USER: guest
|
|
RABBITMQ_PASSWORD: guest
|
|
RABBITMQ_HOST: {{ meta.name }}-rabbitmq.{{ meta.namespace }}.svc.cluster.local
|
|
RABBITMQ_PORT: '5672'
|
|
RABBITMQ_VHOST: awx
|
|
MEMCACHED_HOST: {{ meta.name }}-memcached.{{ meta.namespace }}.svc.cluster.local
|
|
MEMCACHED_PORT: '11211'
|
|
|
|
# Tower Web Deployment.
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: '{{ meta.name }}-tower'
|
|
namespace: {{ meta.namespace }}
|
|
labels:
|
|
app: tower
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
app: tower
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: tower
|
|
spec:
|
|
containers:
|
|
- image: '{{ tower_web_image }}'
|
|
name: tower
|
|
envFrom:
|
|
- configMapRef:
|
|
name: '{{ meta.name }}-tower-configmap'
|
|
- secretRef:
|
|
name: '{{ meta.name }}-tower-secret'
|
|
ports:
|
|
- containerPort: 80
|
|
|
|
# Tower Web Service.
|
|
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: '{{ meta.name }}-tower'
|
|
namespace: '{{ meta.namespace }}'
|
|
labels:
|
|
app: tower
|
|
spec:
|
|
ports:
|
|
- port: 80
|
|
protocol: TCP
|
|
targetPort: 80
|
|
selector:
|
|
app: tower
|