Commit 0f34bed7 authored by Jonas Waeber's avatar Jonas Waeber
Browse files

Add env to start process for tfv

parent 979cd528
...@@ -4,6 +4,7 @@ metadata: ...@@ -4,6 +4,7 @@ metadata:
name: {{ .Values.k8sGroupId }}-{{ .Values.k8sName }}-{{ .Values.k8sEnvironment}}-config name: {{ .Values.k8sGroupId }}-{{ .Values.k8sName }}-{{ .Values.k8sEnvironment}}-config
namespace: memobase namespace: memobase
data: data:
TFV_ENV: {{ .Values.k8sEnvironment }}
TFV_KAFKA_SERVER_CONFIGS: {{ .Values.kafkaConfigs }} TFV_KAFKA_SERVER_CONFIGS: {{ .Values.kafkaConfigs }}
TFV_SFTP_CONFIGS: {{ .Values.sftpConfigs }} TFV_SFTP_CONFIGS: {{ .Values.sftpConfigs }}
TFV_TOPIC_NAME: {{ .Values.tfvTopicName }} TFV_TOPIC_NAME: {{ .Values.tfvTopicName }}
......
...@@ -46,6 +46,7 @@ def create_app(): ...@@ -46,6 +46,7 @@ def create_app():
app.config['tfv-sftp-configs'] = os.environ['TFV_SFTP_CONFIGS'] app.config['tfv-sftp-configs'] = os.environ['TFV_SFTP_CONFIGS']
app.config['tfv-topic-name'] = os.environ['TFV_TOPIC_NAME'] app.config['tfv-topic-name'] = os.environ['TFV_TOPIC_NAME']
app.config['tfv-reporting-topic-name'] = os.environ['TFV_REPORTING_TOPIC_NAME'] app.config['tfv-reporting-topic-name'] = os.environ['TFV_REPORTING_TOPIC_NAME']
app.config['tfv-env'] = os.environ['TFV_ENV']
app.config['SWAGGER'] = { app.config['SWAGGER'] = {
'title': 'Memobase Import API', 'title': 'Memobase Import API',
......
...@@ -53,7 +53,9 @@ class ImportProcessStart(Resource): ...@@ -53,7 +53,9 @@ class ImportProcessStart(Resource):
'kafkaConfigs': current_app.config['tfv-kafka-configs'], 'kafkaConfigs': current_app.config['tfv-kafka-configs'],
'sftpConfigs': current_app.config['tfv-sftp-configs'], 'sftpConfigs': current_app.config['tfv-sftp-configs'],
'topicName': current_app.config['tfv-topic-name'], 'topicName': current_app.config['tfv-topic-name'],
'reportingTopicName': current_app.config['tfv-reporting-topic-name']} 'reportingTopicName': current_app.config['tfv-reporting-topic-name'],
'env': current_app.config['tfv-env']
}
if 'xmlRecordTag' in job_parameters: if 'xmlRecordTag' in job_parameters:
body['xmlRecordTag'] = job_parameters['xmlRecordTag'] body['xmlRecordTag'] = job_parameters['xmlRecordTag']
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment