Skip to content

Configuring networking

Configuring networking

Configure and test a local static network for your operating system (OS) image that enables the following wired network connection capabilities for your system on a chip (SoC):

  • In-vehicle connectivity between electronic control units (ECUs)
  • Wired vehicle-to-cloud (V2C) connectivity
  • Connectivity for applications in the quality-managed (QM) partition

Images built with Automotive Image Builder have two network options:

  • Dynamic Host Configuration Protocol (DHCP), which uses NetworkManager to dynamically assign IP addresses and is useful for development and testing
  • A preconfigured static IP network setup, which uses the “nmstatectl --kernel” feature for efficient, daemon-less configuration

Prerequisites

  • A custom OS image manifest that includes a containerized application in the QM partition

Procedure

  1. Configure the static network for the entire operating system (OS):

    console title="Example OS static network configuration" --8<-- "demos/networking/networking.aib.yml:5:11"

  2. In the content: portion of your manifest, configure the ports for your containerized QM applications by adding a drop-in file to /etc/containers/systemd/qm.container.d/:

    console title="Example systemd directory and configuration file to store container port configurations" --8<-- "demos/container_qm_network/container_qm_network.aib.yml:12:20"

  3. In the content: portion of the qm: section of your manifest, set publish ports for your containerized QM applications and add a subnet to prevent IP address conflicts and routing issues:

    console title="Subnet, port, and static network configurations for an example NGINX QM container" --8<-- "demos/container_qm_network/container_qm_network.aib.yml:27:48"

  4. To be able test the image after you build it, add ssh packages, and then enable the SSH service through systemd, and enableSSH root access:

    1. Add SSH packages to your manifest:

      console title="Extra SSH RPMs" --8<-- "demos/networking/networking.aib.yml:14:17"

    2. Enable the SSH service through systemd:

      console title="SSH service managed by systemd" --8<-- "demos/networking/networking.aib.yml:19:23"

    3. Enable SSH root access:

      console title="SSH root access configuration" --8<-- "demos/networking/networking.aib.yml:25:31"

Next steps
  1. Configure interprocess communications (IPCs) between your containers in the root partition and containers in the QM partition and across partitions.
  2. Encrypt your filesystem.
  3. Enable BlueChi orchestration.
  4. Build your automotive OS image with kernel-automotive or your custom kernel.