diff --git a/ansible-adaptor/swagger_server/controllers/ans_handler.py b/ansible-adaptor/swagger_server/controllers/ans_handler.py index 82191a2..a468cbe 100755 --- a/ansible-adaptor/swagger_server/controllers/ans_handler.py +++ b/ansible-adaptor/swagger_server/controllers/ans_handler.py @@ -310,6 +310,7 @@ def run(self): run an ansible playbook (sync mode) and return Results """ self.logger.info('ansible playbook run started') + self.pbex._tqm._stdout_callback = self.callback self.pbex.run() return self.callback.properties, self.callback.is_run_ok() @@ -320,10 +321,14 @@ def run_async(self): self.logger.info(str(self.request_id) + ': ' + 'ansible playbook run started ' + self.started_at.isoformat()) self.log_request_status('IN_PROGRESS', 'running playbook', '', '') + self.pbex._tqm._stdout_callback = self.callback self.pbex.run() self.finished_at = datetime.now() self.logger.info(str(self.request_id) + ': ' + 'ansible playbook run finished ' + self.finished_at.isoformat()) + self.logger.debug("Ansible facts") + self.logger.debug(json.dumps(self.callback.facts)) + if self.callback.is_run_ok(): self.logger.info(str(self.request_id) + ': ' + 'ansible ran OK') diff --git a/helm/osslm-ansible-resource-manager/Chart.yaml b/helm/osslm-ansible-resource-manager/Chart.yaml index 707c724..d6019fb 100644 --- a/helm/osslm-ansible-resource-manager/Chart.yaml +++ b/helm/osslm-ansible-resource-manager/Chart.yaml @@ -1,6 +1,6 @@ name: osslm-ansible-resource-manager -version: 1.3.1 -appVersion: 1.3.1 +version: 1.3.2 +appVersion: 1.3.2 apiVersion: v1 description: A Helm chart for the osslm-ansible-resource-manager # maintainers: diff --git a/helm/osslm-ansible-resource-manager/README.md b/helm/osslm-ansible-resource-manager/README.md index 4010e61..a70d12d 100644 --- a/helm/osslm-ansible-resource-manager/README.md +++ b/helm/osslm-ansible-resource-manager/README.md @@ -41,7 +41,7 @@ NOTE: You can skip the need for persistent volumes by settings cassandra.persist Install Helm Chart ``` -helm install osslm-ansible-resource-manager-1.2.1.tgz --name osslm-ansible-rm --namespace default --values osslm-ansible-rm.values.yaml --debug +helm install osslm-ansible-resource-manager-1.3.2.tgz --name osslm-ansible-rm --namespace default --values osslm-ansible-rm.values.yaml --debug #helm install osslm-ansible-resource-manager --name osslm-ansible-rm ``` diff --git a/helm/osslm-ansible-resource-manager/templates/deployment.yaml b/helm/osslm-ansible-resource-manager/templates/deployment.yaml index 7eef43f..a51d94c 100644 --- a/helm/osslm-ansible-resource-manager/templates/deployment.yaml +++ b/helm/osslm-ansible-resource-manager/templates/deployment.yaml @@ -33,7 +33,7 @@ spec: volumeMounts: - name: osslm-ansible-rm mountPath: /var/alm_ansible_rm - {{- if .Values.app.config.security.ssl.secretName }} + {{- if and .Values.app.config.security.ssl.enabled .Values.app.config.security.ssl.secretName }} - name: {{ .Values.app.config.security.ssl.secretName }} mountPath: /var/alm_ansible_rm/ssl {{- end }} diff --git a/helm/osslm-ansible-resource-manager/templates/service.yaml b/helm/osslm-ansible-resource-manager/templates/service.yaml index 4744396..2a05e2c 100644 --- a/helm/osslm-ansible-resource-manager/templates/service.yaml +++ b/helm/osslm-ansible-resource-manager/templates/service.yaml @@ -18,5 +18,8 @@ spec: targetPort: 8443 protocol: TCP name: https +{{- if eq .Values.service.type "NodePort" }} + nodePort: {{ .Values.service.sslNodePort }} +{{- end }} selector: app: osslm-ansible-rm \ No newline at end of file diff --git a/helm/osslm-ansible-resource-manager/values.yaml b/helm/osslm-ansible-resource-manager/values.yaml index 99c71fd..a4fa599 100644 --- a/helm/osslm-ansible-resource-manager/values.yaml +++ b/helm/osslm-ansible-resource-manager/values.yaml @@ -1,8 +1,8 @@ ## Docker Image for the osslm-ansible-rm application docker: ## Make this the full path, including registry host and port if using one - image: osslm-ansible-rm - version: 1.2.1 + image: accanto/osslm-ansible-rm + version: 1.3.2 imagePullPolicy: IfNotPresent ## Configuration for the application deployment @@ -59,9 +59,10 @@ app: # us to bundle the log message and other metadata in a json log message and let Fielbeat extract them # as top level fields in the Elasticsearch index. LOG_TYPE: logstash - ssl_enabled: "false" + ssl_enabled: "true" security: ssl: + enabled: true secretName: osslm-ansible-rm-tls persistence: @@ -75,6 +76,7 @@ service: # Using NodePort allows access to the IPs through http://k8s-host:nodePort/ type: NodePort nodePort: 31080 + sslNodePort: 31081 cassandra: enabled: false