From fa42660f8a2149603f3035e2fd30394a782a9358 Mon Sep 17 00:00:00 2001
From: Jan David Mol <mol@astron.nl>
Date: Mon, 7 Jun 2021 10:52:55 +0200
Subject: [PATCH] L2SS-188: Added docker container for Statistics device

---
 docker-compose/device-statistics.yml | 35 ++++++++++++++++++++++++++++
 1 file changed, 35 insertions(+)
 create mode 100644 docker-compose/device-statistics.yml

diff --git a/docker-compose/device-statistics.yml b/docker-compose/device-statistics.yml
new file mode 100644
index 000000000..0a1eee2f2
--- /dev/null
+++ b/docker-compose/device-statistics.yml
@@ -0,0 +1,35 @@
+#
+# Docker compose file that launches an interactive iTango session.
+#
+# Connect to the interactive session with 'docker attach itango'.
+# Disconnect with the Docker deattach sequence: <CTRL>+<P> <CTRL>+<Q>
+#
+# Defines:
+#   - itango: iTango interactive session
+#
+# Requires:
+#   - lofar-device-base.yml
+#
+version: '2'
+
+services:
+  device-statistics:
+    image: device-statistics
+    # build explicitly, as docker-compose does not understand a local image
+    # being shared among services.
+    build:
+        context: lofar-device-base
+    container_name: ${CONTAINER_NAME_PREFIX}device-statistics
+    network_mode: ${NETWORK_MODE}
+    volumes:
+        - ${TANGO_LOFAR_CONTAINER_MOUNT}
+    environment:
+      - TANGO_HOST=${TANGO_HOST}
+    entrypoint:
+      - /usr/local/bin/wait-for-it.sh
+      - ${TANGO_HOST}
+      - --timeout=30
+      - --strict
+      - --
+      - python3 -u ${TANGO_LOFAR_CONTAINER_DIR}/devices/statistics_device.py LTS -v
+    restart: on-failure
-- 
GitLab