Skip to content
This repository has been archived by the owner on Oct 12, 2023. It is now read-only.

Infrastructure

Devis Lucato edited this page Jul 6, 2017 · 5 revisions

Network configuration

The network configuration depends on the way microservices are deployed. Here's a quick summary.

  • When launching a microservice, pass an environment variable specifying the TCP port to use. Each microservice uses a dedicated environment variable, for instance PCS_AUTHENTICATION_WEBSERVICE_PORT, PCS_IOTHUBMANAGER_WEBSERVICE_PORT, PCS_DEVICESIMULATION_WEBSERVICE_PORT etc.
  • Microservices need to talk to each other. Provide the URL of the required services using environment variables, e.g. PCS_IOTHUBMANAGER_WEBSERVICE_URL with value http://127.0.0.1:9002/v1
  • When running the microservices manually from an IDE, Docker or Docker compose, for consistency use the corresponding ports below.
  • When running the microservices with Kubernetes, each container has a dedicated IP, so there is no port conflict. Anyway, for consistency, use the corresponding ports below.
  • when running the microservices with Mesos/Marathon, let Marathon assign the ports automatically (typically ports 10000+), and use the auto-generated environment variables to populate the microservices configuration.

TCP ports assigned to PCS services

Public services:

  • 9001: PCS Authentication web service
  • 9002: IoT Hub Manager web service
  • 9003: Device Simulation web service
  • 9004: Device Telemetry web service
  • 9005: PCS UI Config web service
  • 9006: UX analytics

Internal services:

  • 9021: Authentication adapter web service
  • 9022: Storage Adapter web service
  • 9023: D2C Streaming web service