Enable pushgateway persistent storage

Change-Id: Ic850cadd55b842c784d9271dc62cc46b389604a1
Closes-bug: PROD-21073
diff --git a/docker/swarm/stack/monitoring/pushgateway.yml b/docker/swarm/stack/monitoring/pushgateway.yml
index af108a6..461eb0b 100644
--- a/docker/swarm/stack/monitoring/pushgateway.yml
+++ b/docker/swarm/stack/monitoring/pushgateway.yml
@@ -23,8 +23,11 @@
               environment:
                 PUSHGATEWAY_BIND_PORT: ${prometheus:pushgateway:bind:port}
                 PUSHGATEWAY_BIND_ADDRESS: ${prometheus:pushgateway:bind:address}
+                PUSHGATEWAY_DATA_DIR: ${_param:prometheus_pushgateway_data_directory}
               labels:
                 com.mirantis.monitoring: "pushgateway"
               image: ${_param:docker_image_pushgateway}
               ports:
                 - 15012:${prometheus:pushgateway:bind:port}
+              volumes:
+                - ${prometheus:pushgateway:dir:data}:${_param:prometheus_pushgateway_data_directory}
diff --git a/grafana/client/datasource/prometheus.yml b/grafana/client/datasource/prometheus.yml
index 681b9df..22d5728 100644
--- a/grafana/client/datasource/prometheus.yml
+++ b/grafana/client/datasource/prometheus.yml
@@ -12,4 +12,3 @@
           host: ${_param:grafana_prometheus_address}
           port: ${_param:grafana_prometheus_port}
           is_default: ${_param:grafana_prometheus_is_default}
-
diff --git a/prometheus/pushgateway/container.yml b/prometheus/pushgateway/container.yml
index d0e986e..e4e9cd7 100644
--- a/prometheus/pushgateway/container.yml
+++ b/prometheus/pushgateway/container.yml
@@ -1,2 +1,3 @@
 classes:
 - service.prometheus.pushgateway.container
+- system.prometheus.pushgateway
diff --git a/prometheus/pushgateway/init.yml b/prometheus/pushgateway/init.yml
new file mode 100644
index 0000000..a906807
--- /dev/null
+++ b/prometheus/pushgateway/init.yml
@@ -0,0 +1,7 @@
+parameters:
+  _param:
+    prometheus_pushgateway_data_directory: /opt/pushgateway/data
+  prometheus:
+    pushgateway:
+      dir:
+        data: /srv/volumes/local/pushgateway/data