diff --git a/src/automation/.env.example b/src/automation/.env.example
index e69de29bb2d1d6434b8b29ae775ad8c2e48c5391..35c4e0b97f715c3c0a6ff961f209070eae547590 100644
--- a/src/automation/.env.example
+++ b/src/automation/.env.example
@@ -0,0 +1,5 @@
+# Define the host for the Context Service
+quarkus.kubernetes.env.vars.context-service-host=context
+
+# Define the host for the Device Service
+quarkus.kubernetes.env.vars.device-service-host=device
\ No newline at end of file
diff --git a/src/automation/src/main/java/eu/teraflow/automation/context/ContextGatewayImpl.java b/src/automation/src/main/java/eu/teraflow/automation/context/ContextGatewayImpl.java
index d52638267d718839aefa0826298255451127ac58..6b0ff132efe595f4ba4c618e5ec1697931c90022 100644
--- a/src/automation/src/main/java/eu/teraflow/automation/context/ContextGatewayImpl.java
+++ b/src/automation/src/main/java/eu/teraflow/automation/context/ContextGatewayImpl.java
@@ -14,7 +14,8 @@ import javax.enterprise.context.ApplicationScoped;
 @ApplicationScoped
 public class ContextGatewayImpl implements ContextGateway {
 
-    @GrpcClient ContextService delegate;
+    @GrpcClient("context")
+    ContextService delegate;
 
     @Override
     public Multi<DeviceEvent> getDeviceEvents() {
diff --git a/src/automation/src/main/java/eu/teraflow/automation/device/DeviceGatewayImpl.java b/src/automation/src/main/java/eu/teraflow/automation/device/DeviceGatewayImpl.java
index 38f79eee0d8d9f709a252be5ceb0a6a9e2a7c842..78e72598e681f4f007e541423b0cc64694f7ea3d 100644
--- a/src/automation/src/main/java/eu/teraflow/automation/device/DeviceGatewayImpl.java
+++ b/src/automation/src/main/java/eu/teraflow/automation/device/DeviceGatewayImpl.java
@@ -14,7 +14,8 @@ import javax.enterprise.context.ApplicationScoped;
 @ApplicationScoped
 public class DeviceGatewayImpl implements DeviceGateway {
 
-    @GrpcClient DeviceService deviceDelegate;
+    @GrpcClient("device")
+    DeviceService deviceDelegate;
 
     @Override
     public Uni<eu.teraflow.automation.device.model.DeviceConfig> getInitialConfiguration(
diff --git a/src/automation/src/main/resources/application.yaml b/src/automation/src/main/resources/application.yaml
index e559876bfa312282b766de61c770db09730074a0..2ea1ef12a279b6e94ab7aa2eff1dacb7020c7ac2 100644
--- a/src/automation/src/main/resources/application.yaml
+++ b/src/automation/src/main/resources/application.yaml
@@ -1,10 +1,15 @@
 automation:
-  should-subscribe-to-context-component: false
+  should-subscribe-to-context-component: true
 quarkus:
   grpc:
     server:
       port: 9999
       enable-reflection-service: true
+    clients:
+      context:
+        host: ${quarkus.kubernetes.env.vars.context-service-host}
+      device:
+        host: ${quarkus.kubernetes.env.vars.device-service-host}
   http:
     port: 8080
   container-image:
@@ -31,3 +36,7 @@ quarkus:
       grpc-server:
         host-port: 9999
         container-port: 9999
+    env:
+      vars:
+        context-service-host: context
+        device-service-host: device
\ No newline at end of file
diff --git a/src/automation/target/generated-sources/grpc/context/ContextOuterClass.java b/src/automation/target/generated-sources/grpc/context/ContextOuterClass.java
index 473bfa689e1a6df4d08ed8ddb76c746969f317dd..21d845ecd69f3ec21bdc185dfac5e2cbd171904d 100644
--- a/src/automation/target/generated-sources/grpc/context/ContextOuterClass.java
+++ b/src/automation/target/generated-sources/grpc/context/ContextOuterClass.java
@@ -28708,11 +28708,19 @@ public final class ContextOuterClass {
     context.ContextOuterClass.EndPointIdOrBuilder getEndpointIdOrBuilder();
 
     /**
+     * <pre>
+     *repeated kpi_sample_types.KpiSampleType kpi_sample_types = 3;
+     * </pre>
+     *
      * <code>string endpoint_type = 2;</code>
      * @return The endpointType.
      */
     java.lang.String getEndpointType();
     /**
+     * <pre>
+     *repeated kpi_sample_types.KpiSampleType kpi_sample_types = 3;
+     * </pre>
+     *
      * <code>string endpoint_type = 2;</code>
      * @return The bytes for endpointType.
      */
@@ -28845,6 +28853,10 @@ public final class ContextOuterClass {
     public static final int ENDPOINT_TYPE_FIELD_NUMBER = 2;
     private volatile java.lang.Object endpointType_;
     /**
+     * <pre>
+     *repeated kpi_sample_types.KpiSampleType kpi_sample_types = 3;
+     * </pre>
+     *
      * <code>string endpoint_type = 2;</code>
      * @return The endpointType.
      */
@@ -28862,6 +28874,10 @@ public final class ContextOuterClass {
       }
     }
     /**
+     * <pre>
+     *repeated kpi_sample_types.KpiSampleType kpi_sample_types = 3;
+     * </pre>
+     *
      * <code>string endpoint_type = 2;</code>
      * @return The bytes for endpointType.
      */
@@ -29333,6 +29349,10 @@ public final class ContextOuterClass {
 
       private java.lang.Object endpointType_ = "";
       /**
+       * <pre>
+       *repeated kpi_sample_types.KpiSampleType kpi_sample_types = 3;
+       * </pre>
+       *
        * <code>string endpoint_type = 2;</code>
        * @return The endpointType.
        */
@@ -29349,6 +29369,10 @@ public final class ContextOuterClass {
         }
       }
       /**
+       * <pre>
+       *repeated kpi_sample_types.KpiSampleType kpi_sample_types = 3;
+       * </pre>
+       *
        * <code>string endpoint_type = 2;</code>
        * @return The bytes for endpointType.
        */
@@ -29366,6 +29390,10 @@ public final class ContextOuterClass {
         }
       }
       /**
+       * <pre>
+       *repeated kpi_sample_types.KpiSampleType kpi_sample_types = 3;
+       * </pre>
+       *
        * <code>string endpoint_type = 2;</code>
        * @param value The endpointType to set.
        * @return This builder for chaining.
@@ -29381,6 +29409,10 @@ public final class ContextOuterClass {
         return this;
       }
       /**
+       * <pre>
+       *repeated kpi_sample_types.KpiSampleType kpi_sample_types = 3;
+       * </pre>
+       *
        * <code>string endpoint_type = 2;</code>
        * @return This builder for chaining.
        */
@@ -29391,6 +29423,10 @@ public final class ContextOuterClass {
         return this;
       }
       /**
+       * <pre>
+       *repeated kpi_sample_types.KpiSampleType kpi_sample_types = 3;
+       * </pre>
+       *
        * <code>string endpoint_type = 2;</code>
        * @param value The bytes for endpointType to set.
        * @return This builder for chaining.
diff --git a/src/automation/target/kubernetes/kubernetes.yml b/src/automation/target/kubernetes/kubernetes.yml
index c874443f6235bbf525378ee93fa35738314bf991..a57486db6f17111a43600c943a392fa462112f49 100644
--- a/src/automation/target/kubernetes/kubernetes.yml
+++ b/src/automation/target/kubernetes/kubernetes.yml
@@ -3,8 +3,8 @@ apiVersion: v1
 kind: Service
 metadata:
   annotations:
-    app.quarkus.io/commit-id: 285c0ca58a5b847c5bceed002b5e0fc0dcb5a28a
-    app.quarkus.io/build-timestamp: 2021-11-11 - 13:46:51 +0000
+    app.quarkus.io/commit-id: 43db942bd5641ae293df75b65cd1eefd40b8085e
+    app.quarkus.io/build-timestamp: 2021-11-17 - 06:42:01 +0000
   labels:
     app.kubernetes.io/name: automationservice
     app.kubernetes.io/version: 0.0.1
@@ -27,28 +27,28 @@ apiVersion: apps/v1
 kind: Deployment
 metadata:
   annotations:
-    app.quarkus.io/commit-id: 285c0ca58a5b847c5bceed002b5e0fc0dcb5a28a
-    app.quarkus.io/build-timestamp: 2021-11-11 - 13:46:51 +0000
+    app.quarkus.io/commit-id: 43db942bd5641ae293df75b65cd1eefd40b8085e
+    app.quarkus.io/build-timestamp: 2021-11-17 - 06:42:01 +0000
   labels:
     app: automationservice
-    app.kubernetes.io/version: 0.0.1
     app.kubernetes.io/name: automationservice
+    app.kubernetes.io/version: 0.0.1
   name: automationservice
 spec:
   replicas: 1
   selector:
     matchLabels:
-      app.kubernetes.io/version: 0.0.1
       app.kubernetes.io/name: automationservice
+      app.kubernetes.io/version: 0.0.1
   template:
     metadata:
       annotations:
-        app.quarkus.io/commit-id: 285c0ca58a5b847c5bceed002b5e0fc0dcb5a28a
-        app.quarkus.io/build-timestamp: 2021-11-11 - 13:46:51 +0000
+        app.quarkus.io/commit-id: 43db942bd5641ae293df75b65cd1eefd40b8085e
+        app.quarkus.io/build-timestamp: 2021-11-17 - 06:42:01 +0000
       labels:
         app: automationservice
-        app.kubernetes.io/version: 0.0.1
         app.kubernetes.io/name: automationservice
+        app.kubernetes.io/version: 0.0.1
     spec:
       containers:
         - env:
@@ -56,6 +56,10 @@ spec:
               valueFrom:
                 fieldRef:
                   fieldPath: metadata.namespace
+            - name: CONTEXT_SERVICE_HOST
+              value: context
+            - name: DEVICE_SERVICE_HOST
+              value: device
           image: registry.gitlab.com/teraflow-h2020/controller/automation:0.0.1
           imagePullPolicy: Always
           livenessProbe: